Web Scraping API: send a URL, get the page
One GET request returns the page as HTML, Markdown or JSON. Turn on Headless Chrome, a residential proxy or a country only for the URLs that need it. Plain HTML costs 1 credit.
10,000 free credits every month · no card · failed requests cost 0
# Plain HTML without a browser: 1 credit.
curl --get 'https://api.scrapingant.com/v2/general' \
--data-urlencode "x-api-key=$SCRAPINGANT_API_KEY" \
--data-urlencode 'url=https://example.com/' \
--data-urlencode 'browser=false'import os, requests
# Render the page in Headless Chrome and wait for the product grid: 10 credits.
resp = requests.get(
"https://api.scrapingant.com/v2/general",
params={
"x-api-key": os.environ["SCRAPINGANT_API_KEY"],
"url": "https://example.com/products",
"browser": "true",
"wait_for_selector": ".product-card",
},
timeout=90,
)
print(resp.headers["Ant-credits-cost"])
html = resp.text// Same page as Markdown for an LLM, without a browser: 1 credit.
const qs = new URLSearchParams({
"x-api-key": process.env.SCRAPINGANT_API_KEY,
url: "https://example.com/docs",
browser: "false",
});
const res = await fetch(`https://api.scrapingant.com/v2/markdown?${qs}`);
const { markdown } = await res.json(); Choose the output, keep the same request
All three endpoints take the same key and the same browser, proxy and country parameters.
HTML
The page as the server sent it, or after JavaScript ran in Headless Chrome. Parse it with the selectors you already have.
How rendering works →Markdown
Scripts removed, the rest of the page converted to Markdown, ready to pass to an LLM. Costs the same as the underlying request.
URL to Markdown API →JSON fields
List the fields in plain text, such as title, price(number), and get them back as JSON. Fields it can’t find come back as null.
You pay for the mode each request uses
Every plan is a pool of credits, and each request spends credits by mode. The counts below assume the whole Startup allowance (500,000 credits for $49/month) goes to one mode.
| Request mode | Credits per request | Requests on Startup | Cost per 1,000 |
|---|---|---|---|
Plain HTML, datacenter proxybrowser=false | 1 | 500,000 | $0.098 |
Headless Chrome, page source only, datacenterbrowser=true&return_page_source=true | 2 | 250,000 | $0.196 |
Headless Chrome with JavaScript, datacenterbrowser=true | 10 | 50,000 | $0.98 |
Plain HTML, residential proxybrowser=false&proxy_type=residential | 25 | 20,000 | $2.45 |
Headless Chrome, page source only, residentialbrowser=true&return_page_source=true&proxy_type=residential | 50 | 10,000 | $4.90 |
Headless Chrome with JavaScript, residentialbrowser=true&proxy_type=residential | 125 | 4,000 | $12.25 |
Start with the cheapest mode that works
Send browser=false first. Static pages, sitemaps and JSON endpoints usually don’t need a browser, and that request costs 1 credit. Switch a URL pattern to Headless Chrome or a residential proxy only when the plain response is empty or blocked.
What isn’t charged
Requests that fail on the API side cost nothing. A 200 response that carries the target’s own error page is charged. Each response has an Ant-credits-cost header, so you can log the real cost per URL. Choosing a country doesn’t add to the price.
Requests to Google domains cost 10 credits on datacenter proxies. JSON extraction adds 1 credit per 30 characters of page Markdown and output. On the Business plan (3,000,000 credits for $249/month) plain HTML works out to $0.083 per 1,000. Rates from the credit cost table and the plans below, checked .
Render JavaScript only where the page needs it
React, Vue, Angular and Next.js sites often send an empty <div id="root"> and build the content in the browser. A plain fetch sees the empty shell. With browser=true the request runs in Headless Chrome and you get the HTML after the page’s JavaScript has run.
browser is on by default on /v2/general. Set browser=false on static pages and pay 1 credit instead of 10.
- Same selectors you’d use on the page in your own browser
- No Chrome binaries, Docker images or browser pool on your side
return_page_source=truereturns the server’s HTML from the browser for 2 credits
Wait for the element you need
Pages that load rows or prices over XHR finish in stages. wait_for_selector holds the response until your CSS selector appears in the DOM, then returns the HTML.
- Product grids and tables that fill in after the first paint
- Lists that load more items as you scroll
- Set
timeoutfrom 5 to 60 seconds; the default is 60
Click, scroll or fill a form before the HTML comes back
Encode a piece of JavaScript as Base64 and pass it as js_snippet. It runs in the page after it loads, so you can click “load more”, close a cookie banner or scroll before the response. Pair it with wait_for_selector to wait for the result.
Moving browser steps from another API? The ScrapingBee comparison lists which ones need rewriting.
- Plain DOM JavaScript:
querySelector,click(),scrollTo() - Works only with
browser=true - No localStorage operations; keep Playwright for those
Pick the proxy and country per request
Requests go through datacenter proxies by default. Send proxy_type=residential for targets that block datacenter traffic, and proxy_country to see a site the way a local visitor does. You can mix both in the same batch.
- 50,000+ datacenter and 2,000,000+ residential IPs, per the proxy docs
- 24 documented countries on both proxy types, no geotargeting surcharge
block_resource=image,media,fontskips heavy assets in the browsercookiespasses name/value pairs to the target
Call it from your code, your agent or your workflow tool
The same key and credit pool work everywhere.
Any HTTP client or SDK
It’s a GET request, so curl, requests or fetch are enough. A Python client is available if you prefer one.
AI agents over MCP
Add the hosted MCP server to Claude Code, Cursor or another MCP client, and the agent can read pages as HTML, Markdown or text.
MCP server →No-code and CI
Use the n8n node, the Make app or the GitHub Action to fetch pages and Markdown inside an existing workflow.
n8n integration docs →Comparing web scraping APIs?
Plan-by-plan comparisons with the request modes, limits and places where the other service comes out ahead.
ScraperAPI
5× the credits at $49 for standard one-credit requests, and what the other modes cost.
Compare with ScraperAPI →ScrapingBee
Twice the credits at $49, a mode-by-mode cost table and the parameters to map when you move.
Compare with ScrapingBee →Firecrawl
100,000 credits at $19 against 5,000, and Markdown without a browser for 1 credit a page.
Compare with Firecrawl →Pricing
Industry leading pricing that scales with your business.
|
Plans
|
Enthusiast
100K credits / mo
$19/mo
|
★ Most Popular
Startup
500K credits / mo
$49/mo
|
Business
3M credits / mo
$249/mo
|
Business Pro
8M credits / mo
$599/mo
|
Custom
10M+ credits / mo
$699+/mo
|
|---|---|---|---|---|---|
| Monthly API credits | 100,000 | 500,000 | 3,000,000 | 8,000,000 | 10M+ |
| Support channel | Priority email | Priority email | Priority email | Priority + dedicated | |
| Integration help | Docs only | Custom code snippets | Debug sessions | Priority debug sessions | Full enterprise onboarding |
| Expert assistance | — | ||||
| Custom proxy pools | — | — | |||
| Custom anti-bot avoidances | — | — | |||
| Dedicated account manager | — | — | |||
| Start Free | Start Free → | Start Free | Start Free | Talk to Sales |
What customers say
Reviews from developers who use ScrapingAnt, published on Capterra.
Read reviews on Capterra →★★★★★“Onboarding and API integration was smooth and clear. Everything works great. The support was excellent.”
★★★★★“Great communication with co-founders helped me to get the job done. Great proxy diversity and good price.”
★★★★★“This product helps me to scale and extend my business. The setup is easy and support is really good.”
What is a web scraping API?
It is an HTTP endpoint that fetches a web page for you. You send the target URL, and the service handles the proxy, the browser when the page needs one, and the network errors, then returns the page. With ScrapingAnt that is one GET to /v2/general for HTML, /v2/markdown for Markdown or /v2/extract for JSON fields, with the same key and the same parameters.
How much does one request cost?
It depends on the mode. Plain HTML through a datacenter proxy costs 1 credit, Headless Chrome with JavaScript costs 10, and the same two modes through a residential proxy cost 25 and 125. Requests to Google domains cost 10 on datacenter proxies. On the $49 Startup plan (500,000 credits) that works out to $0.098 per 1,000 plain HTML requests and $0.98 per 1,000 rendered ones. Only successful responses are charged (a target’s error page returned with HTTP 200 counts as one), and every response carries an Ant-credits-cost header with what it spent.
Do I need Headless Chrome for every page?
No, and it costs ten times more, so turn it on only where the content is written by JavaScript. browser defaults to true on /v2/general, so send browser=false for static pages, sitemaps and JSON endpoints. If a plain request returns an empty <div id="root"> or a missing table, switch that URL pattern to browser=true.
Can I get Markdown or JSON instead of HTML?
Yes. /v2/markdown returns the page converted to Markdown, at the cost of the underlying request. /v2/extract takes a plain-text list of the fields you want, such as product title, price(number), and returns them as JSON. It costs 1 credit per 30 characters of page Markdown and output, plus the request.
How many requests can I run at the same time?
Paid plans have no concurrency limit, so you pick the worker count your targets tolerate. The free plan allows one request at a time; a second parallel request gets HTTP 409.
How long can a request take?
Set timeout between 5 and 60 seconds; the default is 60. With browser=true, add wait_for_selector so the response comes back as soon as the element you need is on the page.
Which countries can I route through?
24 countries are documented for proxy_country, on both datacenter and residential proxies, at the normal credit cost of the proxy type. The list is in the proxy settings docs. Leave the parameter out to use any location.
What does the free plan include?
10,000 API credits every month, renewed monthly, with no credit card. It allows one concurrent request and has domain restrictions, so use it to check your parser and request mode before you pick a plan.
When should I keep running my own Playwright or Puppeteer?
When the job is a long interactive session: logging in through several steps, keeping a browser profile, or setting localStorage, which the API does not support. For fetching pages, including ones that need JavaScript, clicks or scrolling before the HTML is ready, the API saves you the browser fleet. The Playwright comparison goes through it case by case.
Can an AI agent use the same API?
Yes, through the ScrapingAnt MCP server. It exposes get_web_page_html, get_web_page_markdown and get_web_page_text, which take url, browser, proxy_type and proxy_country and spend credits at the same rates. In Claude Code it is one claude mcp add command.
Try it on the pages you scrape today
Run your own URLs on the free plan with browser=false first, then turn on rendering or residential proxies where the response needs it.
No card needed. The free plan has domain restrictions and one concurrent request.