RAG Chunking Crawler — Web Pages to Text Chunks
Pricing
from $3.00 / 1,000 rag chunk returneds
RAG Chunking Crawler — Web Pages to Text Chunks
Crawl public web pages into RAG-ready text chunks with your chunk size and overlap, plus source URL, title and headings. USD 7 per 1,000 chunks.
Pricing
from $3.00 / 1,000 rag chunk returneds
Rating
0.0
(0)
Developer
Muhammad Afzal
Maintained by CommunityActor stats
0
Bookmarked
1
Total users
0
Monthly active users
22 days ago
Last modified
Categories
Features
Share
RAG Chunking Crawler reads public web pages from the URLs you give it, optionally follows links on the same site, strips navigation and boilerplate, and returns the text already split into chunks of the size and overlap you choose, each with its source URL, title, and position. It is built for developers loading retrieval-augmented generation (RAG) pipelines, vector databases, and AI agents, and costs USD 7 per 1,000 chunks on the FREE pricing tier (USD 0.007 per chunk) plus a USD 0.005 start fee.
You get one dataset row per chunk, ready to embed. The Actor does not create embeddings and does not run web searches; it starts from your URLs.
What does the RAG chunking crawler return?
Each row is one text chunk from one page.
| Field | What it contains |
|---|---|
content | The chunk text: about chunkSize characters, plus any overlap carried over from the previous chunk |
chunkIndex, totalChunks | Position of this chunk within its page, and the page's chunk count |
sourceUrl | The page the chunk came from |
canonicalUrl | The page's declared canonical URL, or null |
title | Page title (from og:title, <title>, or the first h1) |
description | Meta description, or null |
headingPath | The page's first eight h1–h4 headings, repeated on every chunk of that page |
wordCount | Approximate words in the chunk |
crawlDepth | 0 for a start URL, 1 for pages linked from it, and so on |
contentType | Always web-page |
fetchedAt | UTC time the chunk was produced |
chunkId | A stable ID: a 16-character hash of the page's final URL plus the chunk index, unique for each page and chunk |
The OUTPUT record in the key-value store reports pages fetched, chunks returned and charged, failed requests, the stop reason, and warnings such as pages with no readable text.
How does the chunking work?
Text is split at paragraph boundaries first, then by length.
- The page is parsed as static HTML. Scripts, styles, forms,
nav,header,footer,aside, hidden elements, and elements with acookieorcookiesclass are removed. - Text is collected from headings, paragraphs, list items, code blocks, quotes, and table cells inside
mainorarticlewhen present, otherwise from the whole body. - Paragraphs are joined until the next one would push the chunk past
chunkSize. - A paragraph longer than
chunkSizeis cut at fixed character positions. - The last
chunkOverlapcharacters of each chunk are repeated at the start of the next, so a sentence cut at a boundary keeps its context.
The defaults are 1,200 characters with a 150-character overlap, roughly 200 words per chunk.
How do I turn a website into RAG chunks?
Add one or more start URLs. To read more than those pages, turn on crawlLinks.
| Input | Default | Accepted values |
|---|---|---|
startUrls | https://example.com | 1–100 public http or https URLs |
crawlLinks | false | true follows links on the same domain |
maxPages | 10 | 1–100 pages fetched in the whole run |
maxDepth | 2 | 0–10 link hops from each start URL |
chunkSize | 1200 | 300–5,000 characters |
chunkOverlap | 150 | 0–1,000 characters, always less than chunkSize |
requestTimeoutSecs | 45 | 10–120 seconds per page |
{"startUrls": [{ "url": "https://docs.example.com/guide/" }],"crawlLinks": true,"maxPages": 30,"maxDepth": 2,"chunkSize": 1000,"chunkOverlap": 120}
Duplicate and non-HTTP start URLs are dropped and counted in OUTPUT warnings.
When should you use it, and when not?
Use it when:
- you are building a knowledge base or support bot from documentation, help-center, or policy pages;
- an AI agent needs short, source-linked passages it can cite;
- you want chunking done before the data reaches your embedding step.
Do not use it when:
- The site renders its text with JavaScript. Pages are read as static HTML, so script-built content is missed.
- You want web search results for a question. This Actor needs URLs.
- You need structured fields, tables, or links as JSON. Use HTML to JSON Smart Parser.
- You need one clean article per page with author and reading time. Use Smart Article Extractor.
- You need text from images or scans. Use Extract Text from Image URLs — Image OCR Scraper.
Use it from an AI assistant
RAG Chunking Crawler works from Claude, ChatGPT, Cursor, or any other MCP client through Apify's MCP server. Add https://mcp.apify.com/?tools=muhammadafzal/rag-web-browser to your client and ask, for example: "Crawl up to 20 pages of our help center starting at this URL and give me 800-character chunks I can load into our vector store."
Run it with the API
JavaScript (apify-client):
import { ApifyClient } from 'apify-client';const client = new ApifyClient({ token: process.env.APIFY_TOKEN });const run = await client.actor('muhammadafzal/rag-web-browser').call({startUrls: [{ url: 'https://docs.example.com/guide/' }],crawlLinks: true,maxPages: 20,chunkSize: 800,chunkOverlap: 100,});const { items } = await client.dataset(run.defaultDatasetId).listItems();const docs = items.map((c) => ({ id: `${c.sourceUrl}#${c.chunkIndex}`, text: c.content, title: c.title }));
Python (apify-client 3.x):
import osfrom apify_client import ApifyClientclient = ApifyClient(os.environ["APIFY_TOKEN"])run = client.actor("muhammadafzal/rag-web-browser").call(run_input={"startUrls": [{"url": "https://docs.example.com/guide/"}], "crawlLinks": True, "maxPages": 20})for chunk in client.dataset(run.default_dataset_id).iterate_items():doc_id = f'{chunk["sourceUrl"]}#{chunk["chunkIndex"]}'print(doc_id, chunk["wordCount"], chunk["content"][:60])
Output example
The first row shows what the default input produces for https://example.com (one short paragraph, no headings; text and timestamp shortened or illustrative). The second is an illustrative chunk from a crawled documentation page.
[{"chunkId": "0f115db062b7c0dd-0","sourceUrl": "https://example.com","canonicalUrl": null,"title": "Example Domain","description": null,"headingPath": [],"content": "This domain is for use in documentation examples without needing permission. …","contentType": "web-page","chunkIndex": 0,"totalChunks": 1,"wordCount": 25,"crawlDepth": 0,"fetchedAt": "2026-10-27T09:12:04.511Z"},{"chunkId": "da78b9a52ce0fe71-3","sourceUrl": "https://docs.example.com/guide/configure","canonicalUrl": "https://docs.example.com/guide/configure","title": "Configure the client | Example Docs","description": "Set credentials, regions, and retry options.","headingPath": ["Configure the client", "Credentials", "Retries"],"content": "…retry options apply per request.\n\nRetries\n\nSet maxRetries to control how many times a failed call is repeated…","contentType": "web-page","chunkIndex": 3,"totalChunks": 6,"wordCount": 171,"crawlDepth": 1,"fetchedAt": "2026-10-27T09:14:40.208Z"}]
Use chunkId as your vector-store ID. It is a hash of the full page URL plus chunkIndex, so pages under the same long path never share an ID, and re-reading the same page gives the same IDs for upserts.
Pricing: how much does RAG chunking cost?
You pay per chunk returned, plus a start fee. Apify platform usage is included.
| Event | FREE | BRONZE | SILVER | GOLD, PLATINUM, DIAMOND |
|---|---|---|---|---|
| RAG chunk returned (primary event) | USD 0.007 | USD 0.006 | USD 0.005 | USD 0.003 |
| Per 1,000 chunks | USD 7.00 | USD 6.00 | USD 5.00 | USD 3.00 |
| Actor start, per started GB of allocated memory | USD 0.005 | USD 0.005 | USD 0.005 | USD 0.005 |
The default memory is 1 GB, so a run has one start event.
- Default run,
https://example.com, 1 chunk, FREE tier: USD 0.005 + USD 0.007 = USD 0.012. - A crawl that returns 60 chunks, FREE tier: USD 0.005 + 60 × USD 0.007 = USD 0.425 (USD 0.185 on GOLD).
The chunk count depends on page length and chunkSize: larger chunks mean fewer events. There is no chunk cap in the input, so set a maximum total charge on the run if you need a hard budget. The run stops cleanly before a chunk that the budget cannot cover, and every saved chunk is charged.
Limits and reliability
- Up to 100 start URLs and 100 fetched pages per run, three pages at a time, with two retries per page.
crawlLinksfollows links on the same domain, subdomains included, up tomaxDepth.- The crawler does not read
robots.txtand does not log in. Crawl only sites you are allowed to. - Pages with no readable text produce no chunks and a warning in
OUTPUT. A start URL that redirects to a page already read is skipped, so its chunks are not returned or charged twice. If every request fails, the run ends as failed.
FAQ
What chunk size and overlap should I use for RAG?
Start with the default 1,200 characters and 150 overlap. Use 500–800 characters for precise question answering, or 2,000 or more when answers need more context.
Does it create embeddings or write to my vector database?
No. It returns text chunks and metadata. Embed them with your own model and load them into any vector store.
Can it crawl a whole website?
It can crawl up to 100 pages per run on one domain, up to 10 links deep. Split larger sites into several runs with different start URLs.
Does it work on JavaScript-heavy sites?
Only for text present in the initial HTML. It does not run page scripts.
Why are some chunks shorter than my chunk size?
A chunk ends where the next paragraph would not fit, and the last chunk of a page holds whatever text is left.
Can I search the web with a question instead of giving URLs?
No. It needs URLs. Find pages first, then pass their URLs in startUrls.
Related Actors
- HTML to JSON Smart Parser — Pages, Tables & Links: structured JSON from pages, pasted HTML, or files.
- Smart Article Extractor: clean article text with metadata and reading time.
- AI Web Scraper — Extract Website Data to Structured JSON: named fields extracted with AI.
- Extract Text from Image URLs — Image OCR Scraper: text from screenshots and scans.
- AI Readiness Checker for Website AEO & GEO: check whether a site is ready for AI crawlers.
Legal and responsible use
Only crawl public pages you are permitted to access and reuse. Respect site terms and copyright when you store or redistribute chunked text, and handle any personal data in it under the laws that apply to you.
Last verified: 2026-10-27