n8n web scraping workflows: HTTP node, scheduling, and error handling
An n8n web scraping workflow that survives production has three parts: a node that fetches clean content instead of raw HTML, a schedule trigger that runs on a cadence you control, and an error branch that catches failed requests instead of silently dropping rows. This guide builds all three using n8n's built-in HTTP Request node against the fastCRW scrape API, which returns markdown or structured JSON directly, so you skip the HTML-parsing node entirely.
n8n does not ship a scraping node. The common approach is either a raw HTTP Request against the target site (fragile: JavaScript-rendered pages return an empty shell, and most sites block generic user agents) or a headless-browser sub-workflow (heavy: a Puppeteer or Playwright step inside n8n needs its own container and slows every run). Calling a scrape API from the HTTP Request node keeps the workflow to native nodes only, with rendering and anti-bot handling done upstream.
Workflow 1: scheduled scrape into a table
The most common pattern is "check this page daily and store what changed." Four nodes: Schedule Trigger, HTTP Request, a Set/Edit Fields node to shape the output, and a database node (Postgres, Airtable, Google Sheets).
- Schedule Trigger: set to Cron mode, e.g.
0 6 * * *for 06:00 daily. - HTTP Request node: POST to the scrape endpoint. Method: POST, URL:
https://api.fastcrw.com/v1/scrape, Authentication: Generic Credential Type > Header Auth with header nameAuthorizationand valueBearer crw_live_your_key. Body (JSON):
{
"url": "https://example.com/pricing",
"formats": ["markdown"],
"onlyMainContent": true
}
The response body carries data.markdown and data.metadata. In the next node, reference it as {{ $json.data.markdown }}.
- Edit Fields node: map
data.markdown,data.metadata.title, and a timestamp expression{{ $now.toISO() }}into the columns your table expects. - Database node: append or upsert the row. For change detection, hash the markdown (an Edit Fields expression with a small crypto function, or a Code node with two lines) and compare against the last stored hash before writing.
Test with the pin icon on the HTTP Request node before wiring the rest, the fastest way to see the real response shape is to run that single node and inspect its output panel, not to guess from docs.
Workflow 2: batch scrape a list of URLs
For enrichment workflows (a spreadsheet of company URLs that needs a description or contact page pulled for each row), loop over the input with a Split In Batches node so you don't fire hundreds of requests at once.
- Source node (Google Sheets / Airtable / a Code node with an array) feeding one URL per item.
- Split In Batches: batch size 5 to 10, so the HTTP Request node inside the loop runs a bounded number of concurrent items per pass rather than the whole list at once.
- HTTP Request node inside the loop, URL set from the item:
{{ $json.url }}substituted into the same POST body as above. - Merge back into the original sheet by row ID once the loop completes.
If you only need URLs discovered from a site rather than a fixed list, replace step 1 with a single HTTP Request to the map endpoint, which returns every URL on a domain in one call instead of a crawl job:
POST https://api.fastcrw.com/v1/map
{
"url": "https://example.com"
}
The response's data.links array is exactly the array Split In Batches expects next.
Workflow 3: crawl and poll for completion
Crawling a whole site is asynchronous: you start a job and poll until it finishes, rather than waiting on one long HTTP call. n8n handles this with an HTTP Request to start the crawl, then a Wait node plus a loop back to a status-check HTTP Request.
- Start crawl: POST
https://api.fastcrw.com/v1/crawlwith{"url": "https://example.com", "limit": 50, "maxDepth": 2}. The response returns a jobid. - Wait node: 15 to 30 seconds.
- Status check: GET
https://api.fastcrw.com/v1/crawl/{{ $json.id }}. - IF node: branch on
{{ $json.status }}. Ifscraping, loop back to the Wait node. Ifcompleted, continue to processing; iffailed, route to the error branch below.
Set a max-iteration guard (a counter in a Code node, or n8n's built-in loop limit) so a stuck job doesn't poll forever and eat your workflow's execution quota.
Error handling: don't let one bad URL kill the run
The HTTP Request node's default behavior is to stop the whole workflow on a non-2xx response. For a batch of 50 URLs, one dead link should not abort the other 49. Fix this in two settings:
- On the HTTP Request node, open Settings > On Error and set it to Continue (using error output). This adds a second output branch on the node that fires only on failure, carrying the error message in
$json.error. - Wire that error output to a logging step (append the failed URL + error to a "failures" sheet or table) instead of leaving it disconnected, which silently drops the item.
For a workflow-level safety net, add an Error Trigger node as a separate trigger in the same workflow (or a dedicated error-handling workflow referenced in Workflow Settings > Error Workflow). It fires on any unhandled node failure and can post to Slack or email, so a schema change on the target site or an expired API key surfaces immediately instead of showing up as "the sheet stopped updating" three days later.
A distinct failure mode worth branching on separately: a 200 response where the target page returned a bot-detection wall instead of real content. Check data.metadata.statusCode and the length of data.markdown: a suspiciously short markdown body (under a few hundred characters) on a page you know has more content is a signal to retry with renderJs: true in the request body rather than treat it as success.
| Failure type | Where it shows up | Fix in n8n |
|---|---|---|
| Target site down / timeout | HTTP Request node, non-2xx or timeout | Error output branch → log row, continue loop |
| Invalid API key | 401 on every request | Error Workflow → alert immediately, don't retry per-item |
| Rate limit hit | 429 responses mid-batch | Reduce Split In Batches size; add Wait node between batches |
| Bot wall / thin content | 200 but tiny markdown body | IF node on content length → retry with renderJs true |
| Crawl job stuck | Status stays "scraping" indefinitely | Loop counter cap → route to error log after N polls |
Which scraping approach fits an n8n workflow
The right node choice depends on what the target site needs and how much you want n8n itself to manage.
| Approach | Nodes needed | Handles JavaScript pages | Handles anti-bot |
|---|---|---|---|
| Raw HTTP Request to target site | 1 | No | No |
| HTTP Request + HTML Extract node | 2-3 | No | No |
| Headless browser sub-workflow (Puppeteer container) | 3+ and a separate service | Yes | Manual, per-site |
| HTTP Request to a scrape API | 1 | Yes (auto-escalated server-side) | Handled upstream |
For a handful of static pages, a raw HTTP Request plus n8n's HTML Extract node is genuinely enough and adding an external API is unnecessary. Reach for a scrape API when the target renders content with JavaScript, blocks generic clients, or when the workflow needs markdown/structured JSON directly instead of a DOM you'd parse yourself. In an independent test against Firecrawl's own 1,000-URL benchmark set, fastCRW's scrape endpoint measured 63.74% truth-recall (522 of 819 labeled URLs) against Crawl4AI's 59.95% and Firecrawl's 56.04%, at 87.7% scrape success (877/1,000) with 0 thrown errors across 3,000 requests (diagnose_3way.py, 2026-05-08). Full methodology is on the benchmarks page.
Structured extraction inside the same workflow
If the goal isn't the whole page but specific fields (price, availability, contact email), skip the markdown-then-Code-node-regex step and ask the extract endpoint for a JSON schema directly:
POST https://api.fastcrw.com/v1/extract
{
"urls": ["https://example.com/product"],
"schema": {
"type": "object",
"properties": {
"price": { "type": "string" },
"inStock": { "type": "boolean" }
}
}
}
The response's data object matches your schema, so the next node in n8n can map straight into your table columns with no parsing logic in the workflow at all. Extract runs an LLM behind the schema, so it costs more per page than a plain scrape and adds latency, but it removes an entire branch of the workflow (write once, or spend n8n nodes writing a regex that breaks the next time the page's HTML changes).
Credentials and rate limits
Store the API key as an n8n credential (Header Auth), never pasted into the node body, so it does not appear in exported workflow JSON or execution logs. On the target API side, fastCRW's free tier includes 1,000 one-time credits (no card required) and each scrape, crawl page, or map page costs 1 credit; self-hosting the engine is free under AGPL-3.0 if you'd rather run it yourself and have n8n's HTTP Request node point at localhost instead. See pricing for the cloud tiers, or the GitHub repo to self-host.
Where fastCRW is not the right tool: if you're scraping a single static page you fully control and don't need JS rendering, a raw HTTP Request node is simpler and free of any external dependency. And if the target explicitly disallows automated access in its terms, no API changes that.
Sources
- n8n HTTP Request node documentation
- n8n Schedule Trigger node documentation
- n8n error handling documentation
- fastCRW 3-way scrape benchmark,
diagnose_3way.py, 2026-05-08, Firecrawl's public 1,000-URL dataset - fastCRW on GitHub
