πŸš€ We are hiring! See open positions

ZenRows to Scrapfly Migration Guide

Complete parameter mapping and code examples for migrating from ZenRows to Scrapfly. Most teams complete migration in under 2 hours with zero downtime.

Complete Parameter Mapping

ZenRows and Scrapfly share similar parameter names with minor differences. This table shows exact mappings for all features.

ZenRows Parameter Scrapfly Parameter Notes
apikey key API authentication key
url url Target URL to scrape (same)
js_render render_js Enable JavaScript rendering (true/false)
antibot asp Anti-bot bypass (Anti-Scraping Protection)
premium_proxy proxy_pool Use public_residential_pool for residential proxies
proxy_country country 2-letter ISO country code (e.g., "us", "gb")
wait rendering_wait Wait time in milliseconds before returning response
wait_for wait_for_selector CSS selector to wait for before rendering complete
custom_headers headers Custom HTTP headers (JSON format)
session_id session Session name for persistent cookies/state
css_extractor extraction_template Use Scrapfly's Extraction API for structured data
autoparse extraction_model Auto-parse structured data. Use product, article, etc.
output format Output format: raw, markdown, text, clean_html
block_resources N/A (auto-optimized) Scrapfly auto-optimizes rendering. Use format_options for content filtering
screenshot screenshots Capture screenshots (use Screenshot API or screenshots param)
device os Operating system for browser fingerprint (desktop/mobile)
json_response format Response format: raw, markdown, text, clean_html
original_status proxy_response Return original HTTP status code from target
N/A cache Enable response caching (Scrapfly exclusive)
N/A cache_ttl Cache time-to-live in seconds (Scrapfly exclusive)
N/A auto_scroll Automatically scroll page to load lazy content (Scrapfly exclusive)
N/A tags Custom tags for request tracking (Scrapfly exclusive)
N/A correlation_id Custom correlation ID for request tracking (Scrapfly exclusive)
N/A webhook Webhook name for async notifications (Scrapfly exclusive)

Migration Code Examples

Side-by-side code examples showing how to migrate from ZenRows to Scrapfly. Select your language below.

ZenRows
from zenrows import ZenRowsClient

client = ZenRowsClient("YOUR_ZENROWS_API_KEY")

params = {
    "js_render": "true",
    "antibot": "true",
    "premium_proxy": "true",
    "proxy_country": "us",
    "wait": 5000
}

response = client.get(
    "https://example.com",
    params=params
)

print(response.text)
Scrapfly
from scrapfly import ScrapflyClient, ScrapeConfig

client = ScrapflyClient(key="YOUR_SCRAPFLY_API_KEY")

result = client.scrape(ScrapeConfig(
    url="https://example.com",
    render_js=True,
    asp=True,
    proxy_pool="public_residential_pool",
    country="us",
    rendering_wait=5000
))

print(result.content)
ZenRows
const { ZenRows } = require("zenrows");

const client = new ZenRows("YOUR_ZENROWS_API_KEY");

const url = "https://example.com";
const params = {
    js_render: "true",
    antibot: "true",
    premium_proxy: "true",
    proxy_country: "us",
    wait: 5000
};

client.get(url, params)
    .then(response => {
        console.log(response.data);
    });
Scrapfly
const { ScrapflyClient } = require('scrapfly-sdk');

const client = new ScrapflyClient({
    key: 'YOUR_SCRAPFLY_API_KEY'
});

const result = await client.scrape({
    url: 'https://example.com',
    render_js: true,
    asp: true,
    proxy_pool: 'public_residential_pool',
    country: 'us',
    rendering_wait: 5000
});

console.log(result.result.content);
ZenRows
curl "https://api.zenrows.com/v1/\
?url=https%3A%2F%2Fexample.com\
&apikey=YOUR_ZENROWS_API_KEY\
&js_render=true\
&antibot=true\
&premium_proxy=true\
&proxy_country=us\
&wait=5000"
Scrapfly
curl "https://api.scrapfly.io/scrape\
?key=YOUR_SCRAPFLY_API_KEY\
&url=https%3A%2F%2Fexample.com\
&render_js=true\
&asp=true\
&proxy_pool=public_residential_pool\
&country=us\
&rendering_wait=5000"

πŸ€– AI Migration Assistant

Use Claude or ChatGPT to automatically convert your ZenRows code to Scrapfly. Copy this prompt and paste it along with your existing code.

Copy This Prompt

I'm migrating from ZenRows to Scrapfly. Here's my current code using ZenRows' API.
Please convert it to use Scrapfly's Python SDK (or JavaScript SDK if my code is in JavaScript).

Key parameter mappings:
- apikey β†’ key
- js_render β†’ render_js
- antibot β†’ asp
- premium_proxy=true β†’ proxy_pool="public_residential_pool"
- proxy_country β†’ country (same name, different parameter)
- wait β†’ rendering_wait
- wait_for β†’ wait_for_selector
- custom_headers β†’ headers
- session_id β†’ session
- css_extractor β†’ extraction_template (use Scrapfly Extraction API)
- autoparse β†’ extraction_model (use "product", "article", etc.)
- output β†’ format (values: raw, markdown, text, clean_html)
- block_resources β†’ N/A (Scrapfly auto-optimizes)
- screenshot β†’ screenshots
- device β†’ os
- json_response β†’ format (values: raw, markdown, text, clean_html)
- original_status β†’ proxy_response

Scrapfly SDK Docs (markdown for LLM): https://scrapfly.io/docs/sdk/python?view=markdown
Scrapfly API Docs (markdown for LLM): https://scrapfly.io/docs/scrape-api/getting-started?view=markdown

My current ZenRows code:
[PASTE YOUR CODE HERE]
How to Use:
  1. Copy the prompt above
  2. Open Claude or ChatGPT
  3. Paste the prompt and replace [PASTE YOUR CODE HERE] with your ZenRows code
  4. Review the generated Scrapfly code and test it with your free 1,000 credits

Developer Tools: Use our cURL to Python converter and selector tester to speed up development.

Frequently Asked Questions

How do I handle ZenRows' premium_proxy=true?

In Scrapfly, use proxy_pool="public_residential_pool" instead of a boolean flag:

# ZenRows
premium_proxy = "true"

# Scrapfly
proxy_pool = "public_residential_pool"  # For residential proxies

What if I'm using ZenRows' CSS extractor?

Scrapfly's Extraction API is more powerful:

  • Template extraction: Similar to ZenRows CSS extractor, but more flexible
  • Auto-extraction: Automatically detect and extract common data types
  • LLM extraction: Use natural language prompts for complex extraction

Do I need to change my session management?

ZenRows uses session_id, Scrapfly uses session. The functionality is the same:

# ZenRows
session_id = "my-session"

# Scrapfly
session = "my-session"

Learn more about sessions

How do I test my migration?

  1. Sign up for free: Get 1,000 API credits with no credit card required
  2. Run parallel testing: Keep ZenRows running while testing Scrapfly
  3. Compare results: Verify that Scrapfly returns the same data
  4. Gradual migration: Switch traffic gradually (e.g., 10% β†’ 50% β†’ 100%)

Start Your Migration Today

Test Scrapfly on your targets with 1,000 free API credits. No credit card required.

  • 1,000 free API credits
  • Full API access
  • Migration support
  • Same-day response from our team
Start For Free

Need help with migration? Contact our team