Scrape

Pull named fields out of a page with CSS selectors — deterministic, no AI tokens.

POST /api/v1/scrape MCP scrape renderfree

`mode: raw` is free; `rendered` consumes browser minutes.

Playground

Page to scrape.
Map of output field name to CSS selector (see the suffix DSL above).
raw = HTTP fetch. rendered = headless Chromium.
User-agent persona. Many sites serve different HTML per persona — googlebot often returns the pre-rendered version.
Advanced options (3)
Hard timeout for the page load, in milliseconds.
Raw UA string, used only when userAgent is custom.
Block until this CSS selector appears. Useful for lazily hydrated SPAs.
Runs against this deployment's live API.

Result

Fill in the form and hit Run.

Call it from code

How it works

Give it a map of fieldName -> selector and get back a flat JSON object. No model in the loop, so results are repeatable and cost nothing beyond the fetch.

The selector value supports a tiny suffix DSL:

Syntax Meaning
h1 text of the first match
a@href the href attribute of the first match
.item[] array of texts for every match
.item[]@data-id array of attribute values
article@html inner HTML of the first match

When a page needs JavaScript, set mode: "rendered". When the structure is too irregular for selectors, reach for extract-data instead.

Parameters

ParameterTypeDefaultDescription
url * string Page to scrape.
selectors * object Map of output field name to CSS selector (see the suffix DSL above).
mode `raw` | `rendered` "raw" raw = HTTP fetch. rendered = headless Chromium.
userAgent `chrome-desktop` | `chrome-android` | `safari-iphone` | `googlebot` | `bingbot` | `curl` | `custom` "chrome-desktop" User-agent persona. Many sites serve different HTML per persona — googlebot often returns the pre-rendered version.
userAgentString string Raw UA string, used only when userAgent is custom.
waitForSelector string Block until this CSS selector appears. Useful for lazily hydrated SPAs.
timeoutMs integer 20000 Hard timeout for the page load, in milliseconds.

Response

`data` holds one key per selector; `missing` lists selectors that matched nothing.

ParameterTypeDefaultDescription
url string Final URL.
data object Extracted fields.
missing string[] Field names whose selector matched nothing.

Pairs well with