n8n Integration
Use all 28 CrawlForge web scraping tools inside n8n workflows. Connect natively through n8n's MCP Client node over Streamable HTTP, or call the REST API from the HTTP Request node — both paths are verified end-to-end.
Two Ways to Connect
n8n can talk to CrawlForge over two protocols. Pick the one that matches where your n8n runs.
Native MCP
REST API
Option 1: MCP Client Node
n8n ships a built-in MCP Client node (plus an MCP Client Tool sub-node for AI Agent workflows). It speaks MCP's Streamable HTTP transport — the same transport the CrawlForge MCP server exposes in HTTP mode. This guide was verified end-to-end on n8n 2.1.3: the node connects, lists all 28 tools, and executes them.
--http flag switches it to Streamable HTTP. Your API key does double duty: it authenticates the server to CrawlForge, and it is the Bearer token n8n must present.CRAWLFORGE_API_KEY=cf_live_your_api_key_here \
npx crawlforge-mcp-server --http
# MCP endpoint: http://localhost:10000/mcp
# Health check: http://localhost:10000/health
# Set PORT to listen somewhere other than 10000- Server Transport: HTTP Streamable (the default)
- MCP Endpoint URL:
http://localhost:10000/mcp— orhttp://host.docker.internal:10000/mcpwhen n8n runs in Docker on the same machine - Authentication: Bearer Auth — create a credential whose token is the same CrawlForge API key the server was started with
Open the Tool dropdown — n8n connects to the server and lists all 28 CrawlForge tools. Select one (e.g. fetch_url), and with Input Mode: Manual n8n renders the tool's parameters as form fields. Click Execute step to run it; the tool result appears as the node's output, ready to wire into any downstream node.
localhost on your host machine. Use http://host.docker.internal:10000/mcp as the endpoint URL instead.Option 2: HTTP Request Node
Every CrawlForge tool is also a REST endpoint at https://www.crawlforge.dev/api/v1/tools/<tool_name>. This needs no server of your own, so it is the right choice for n8n Cloud (which cannot reach a localhost MCP endpoint). Add an HTTP Request node and configure it:
// Method: POST
// URL: https://www.crawlforge.dev/api/v1/tools/extract_content
// Headers
{
"X-API-Key": "cf_live_your_api_key_here",
"Content-Type": "application/json"
}
// Body (JSON)
{
"url": "https://example.com/article"
}The n8n workflow automation guide builds a complete production pipeline on this pattern — reusable credentials, a scheduled price monitor, error handling, and Slack notifications. Tool parameters and response shapes are in the API reference.
Which option should you use?
| MCP Client node | HTTP Request node | |
|---|---|---|
| Works on n8n Cloud | Only with a publicly hosted MCP server | Yes |
| Runs your own server | Yes — one npx command | No |
| Tool discovery | Automatic — all 28 tools listed in the node | Manual — one endpoint per tool |
| Parameter input | Generated from the tool's schema | Hand-written JSON body |
| AI Agent tool use | Yes, via MCP Client Tool sub-node | No |
Credit Costs
Both connection methods bill the same per-tool credit costs against your API key — for example fetch_url is 1 credit, extract_content is 2, and search_web is 5. The full table is in the API reference; the free plan's one-time 1,000 credits are plenty for building and testing workflows.
Troubleshooting
| Symptom | Fix |
|---|---|
| 401 Unauthorized from the MCP Client node | The Bearer credential must exactly match the CRAWLFORGE_API_KEY the server was started with — they are compared as strings. |
| Connection refused / could not connect | The server isn't running in HTTP mode, or n8n runs in Docker and the endpoint says localhost — use host.docker.internal. |
| Tool dropdown stays empty | Check Server Transport is *HTTP Streamable* and the endpoint path ends in /mcp. Verify the server is healthy: curl http://localhost:10000/health. |
| 402 Payment Required on tool execution | The account behind the API key is out of credits — check usage on the dashboard. |