BlogGuides
How to give your AI agent web access (free, open source)
Practical ways to connect coding agents to live web search and scrape with Webcrawl MCP, CLI, and REST. Free hosted credits and MIT self-host.
Agents that cannot fetch the live web fill gaps from training data. That is fine for trivia and terrible for “what does this docs page say today?” This guide shows how to give an AI agent real web access with Webcrawl: hosted MCP, local MCP, CLI, and REST. You can start on the free hosted tier (1,000 credits a month, no card) or self-host the MIT engine. Checked 2026-11-28.
Related reading: AI agent web access use case, best MCP servers for web scraping, what is an MCP server.
#What should “web access” give an AI agent?
For coding agents and tool-using LLMs, web access usually means four verbs:
- Search the public web for candidate URLs
- Scrape a URL into Markdown the model can quote
- Map or crawl a docs origin when you need coverage
- Extract structured fields when you need JSON, not prose
Webcrawl exposes those as POST /v1/search, /v1/scrape, /v1/map, /v1/crawl, and /v1/extract, plus MCP tools that call the same engine. Credit costs are published on /health (creditSchedule) and pricing.
#How do you connect hosted MCP (fastest for Claude, Cursor, Codex)?
npx webcrawl setup --agent cursor
# or
npx webcrawl setup --agent claude
npx webcrawl setup --agent codex
Hosted config shape:
{
"mcpServers": {
"webcrawl": { "url": "https://webcrawl.app/mcp" }
}
}
Claude CLI:
claude mcp add --transport http webcrawl https://webcrawl.app/mcp
Step-by-step install notes live on Claude Code, Cursor, and Codex.
#How do you run local MCP with an API key?
npx webcrawl login
{
"mcpServers": {
"webcrawl": {
"command": "npx",
"args": ["-y", "@webcrawl/mcp"],
"env": { "WEBCRAWL_API_KEY": "YOUR_API_KEY" }
}
}
}
Local MCP is the right default for headless agents and CI-like sandboxes where interactive sign-in is awkward.
#How do you wire REST or @webcrawl/client in your own tools?
When the runtime is LangChain, LlamaIndex, Mastra, CrewAI, the OpenAI Agents SDK, or a custom router, wrap the API yourself. We do not publish official packages for those frameworks; the honest guides are under integrations. For converting a single page into LLM-ready Markdown, see the URL to Markdown API guide.
npm install @webcrawl/client
import { createClient } from "@webcrawl/client";
const client = createClient({ apiKey: process.env.WEBCRAWL_API_KEY });
const page = await client.scrape({ url: "https://example.com/docs" });
console.log(page.markdown);
#How do you use it free and open source without a card?
- Hosted free tier: 1,000 credits a month on webcrawl.app (see pricing)
- MIT engine: brainfish-ai/webcrawl-anything with npm packages
webcrawl,@webcrawl/mcp, and@webcrawl/client - Free tools (rate limited): website to Markdown, URL extractor
npx webcrawl doctor
npx webcrawl scrape https://example.com/docs
#Which prompt patterns work best?
- “Search for the official docs for X, scrape the getting-started URL, and quote the install commands.”
- “Map https://example.com/docs, list API reference URLs, then scrape the auth page.”
- “Extract plan names and prices from https://example.com/pricing as JSON.”
#When should you use something else?
- Need a marketplace Actor for one stubborn site: compare Apify
- Already standardized on Firecrawl SDKs: read compare Firecrawl
- Looking for Tavily alternatives or a sourced Webcrawl vs Tavily comparison
- Looking for SerpAPI alternatives or a sourced Webcrawl vs SerpAPI comparison
- Looking for Exa alternatives or a sourced Webcrawl vs Exa comparison
- Looking for a Jina Reader alternative for URL to markdown
- Shopping a broader LLM scraping shortlist: best web scraping APIs for LLMs in 2026
#FAQ
#What is the fastest way to give Claude Code or Cursor web access?
Run npx webcrawl setup --agent claude or npx webcrawl setup --agent cursor. It registers https://webcrawl.app/mcp and walks through OAuth with 1,000 free monthly credits.
#How much does Webcrawl cost for an individual developer?
The hosted free tier gives 1,000 credits per month with no credit card required, and the underlying engine is MIT-licensed if you want to self-host without credit limits.
#Should an agent use search, map, or scrape first?
Use search when you do not know the URL yet, map when you know the domain and want its page list, and scrape once you have the exact URLs to read.
#Bottom line
Give agents web access with tools that map to real endpoints, publish credits, and offer a self-host path. Webcrawl’s MCP + REST + MIT engine is built for that loop. Start with npx webcrawl setup, verify with a scrape, then wrap REST only when your framework does not speak MCP.