CSS Selector Scraper – no-code, XPath, pagination – $0.8/1k avatar

CSS Selector Scraper – no-code, XPath, pagination – $0.8/1k

Pricing

$0.80 / 1,000 scraped rows

Go to Apify Store
CSS Selector Scraper – no-code, XPath, pagination – $0.8/1k

CSS Selector Scraper – no-code, XPath, pagination – $0.8/1k

Scrape any public website without code: CSS/XPath fields, repeated items, next-page pagination, 1-level detail links, JSON-LD & meta tags. Fast HTTP, no browser. Works with AI agents via Apify MCP. Pay per row; blocked rows are free.

Pricing

$0.80 / 1,000 scraped rows

Rating

0.0

(0)

Developer

Henry Crawl

Henry Crawl

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

17 hours ago

Last modified

Features

Limited permissions

Share

CSS Selector Scraper – no-code web scraper (CSS / XPath)

Turn any public web page into clean JSON rows without writing code: list the fields you want as CSS or XPath selectors and the actor does the rest – repeated items, next-page pagination, one level of detail pages, JSON-LD and meta tags. It uses fast plain HTTP (no browser), so runs finish in seconds and cost very little.

Great for AI agents: an agent can look at a page, write the selectors and call this actor through Apify MCP.

What it does

  • Item mode – set itemSelector (e.g. article.product_pod): every match becomes one row, field selectors run inside it.
  • Page mode – leave itemSelector empty: one row per page (optionally with meta tags and JSON-LD).
  • Pagination – nextPageSelector (e.g. li.next a, a[rel=next]) is followed up to maxPages.
  • Detail pages – linkSelector (e.g. article h3 a) opens each linked page (1 level deep) and extracts the fields there.
  • CSS or XPath – selectors starting with /, ./, ( or xpath: are XPath (e.g. //th[text()='UPC']/following-sibling::td).
  • Blocked pages (403 / 429 / captcha / bot-check) come back as free BLOCKED rows. The actor does not try to bypass protections; JavaScript-only sites need a browser actor.

Input

FieldDescription
startUrlsPages to start from, [{"url": "https://..."}]
itemSelectorOptional CSS/XPath for repeated items
fieldsList of {"name", "selector", "attr", "multiple"}. attr: text (default), html, outerHtml, href/src (made absolute) or any attribute. multiple: true returns a list
nextPageSelector, maxPagesPagination link and how many pages per start URL (default 10)
linkSelector, maxLinksPerPageDetail links to open, 1 level deep
includeMetaPage mode: title, description, canonical, language, H1, Open Graph / Twitter tags (on by default when no fields)
includeJsonLdPage mode: all schema.org JSON-LD blocks
useApifyProxyUse Apify datacenter proxy (off by default)
maxResultsMax charged rows for the run

Example input

{
"startUrls": [{"url": "https://books.toscrape.com/"}],
"itemSelector": "article.product_pod",
"fields": [
{"name": "title", "selector": "h3 a", "attr": "title"},
{"name": "price", "selector": ".price_color"},
{"name": "productUrl", "selector": "h3 a", "attr": "href"},
{"name": "rating", "selector": "p.star-rating", "attr": "class"}
],
"nextPageSelector": "li.next a",
"maxPages": 3,
"maxResults": 60
}

Detail pages with XPath:

{
"startUrls": [{"url": "https://books.toscrape.com/catalogue/category/books/travel_2/index.html"}],
"linkSelector": "article.product_pod h3 a",
"fields": [
{"name": "title", "selector": "h1"},
{"name": "price", "selector": ".product_main .price_color"},
{"name": "upc", "selector": "//th[text()='UPC']/following-sibling::td"},
{"name": "breadcrumbs", "selector": ".breadcrumb li a", "multiple": true}
]
}

Output

FieldDescription
pageUrl / urlListing page (item mode) or page URL (page / detail mode)
pageNumber, itemIndexPosition of the row
your fieldsOne key per field name
sourcePageUrlListing page a detail page came from
meta, jsonLdWhen enabled (page mode)
type, status, scrapedAtresult / OK, or error with a code: BLOCKED, HTTP_ERROR, NO_ITEMS, NO_LINKS, BAD_FIELD, BAD_SELECTOR, UNSUPPORTED_CONTENT, FETCH_FAILED

Real rows from a test run:

{"pageUrl": "https://books.toscrape.com/", "pageNumber": 1, "itemIndex": 0, "title": "A Light in the Attic", "price": "£51.77", "productUrl": "https://books.toscrape.com/catalogue/a-light-in-the-attic_1000/index.html", "image": "https://books.toscrape.com/media/cache/2c/da/2cdad67c44b002e7ead0cc35693c0e8b.jpg", "rating": "star-rating Three", "availability": "In stock", "type": "result", "status": "OK", "scrapedAt": "2026-11-22T13:59:00.769013+00:00"}
{"url": "https://books.toscrape.com/catalogue/its-only-the-himalayas_981/index.html", "pageNumber": 1, "title": "It's Only the Himalayas", "price": "£45.17", "upc": "a22124811bfa8350", "breadcrumbs": ["Home", "Books", "Travel"], "sourcePageUrl": "https://books.toscrape.com/catalogue/category/books/travel_2/index.html", "type": "result", "status": "OK"}
{"status": "BLOCKED", "error": "The site blocked this request (HTTP 403). Not bypassed; not charged.", "url": "https://httpbin.org/status/403", "httpStatus": 403, "type": "error"}

Pricing

Pay per event: $0.80 per 1,000 rows ($0.0008 per row). Error and blocked rows are free. maxResults and your run spending limit are always respected.

Use with AI agents (MCP)

Add this actor as a tool to Claude, Cursor or any MCP client:

https://mcp.apify.com/?tools=henrycrawl/css-selector-scraper

The agent passes startUrls plus the selectors it wants and gets structured JSON back – a quick way to give an agent "read this table / list from any site" skills.

Limits

  • No JavaScript rendering: content loaded by client-side JS is not visible (use the page's JSON API or a browser actor).
  • Only public pages; no login, no captcha solving.