NewAnswers MCP: one question, one checked answer for your agent.See how it works

Guides

Web search in Claude: turn it on in the app, Claude Code, the API and MCP

By , founder of HyperresearchPublished

Claude can search the web on every plan, Free included. In the claude.ai app, click the + button at the lower left of the chat box and select Web search; a checkmark shows it is on. If your account has the new Claude experience there is no toggle at all, because Claude searches when it helps. In Claude Code, web search is built in as the WebSearch tool and only needs your approval the first time. In the Claude API, add a tool of type web_search_20260318 to the request; it costs $10 per 1,000 searches plus tokens.

Everything below was read from Anthropic’s help center, the Claude Platform docs and the Claude Code docs on November 15, 2026. Many guides that rank for these queries still describe the March 2025 launch, when search was a US-only preview for paid users switched on in profile settings. Since May 27, 2025 it has been available globally on all plans.

Claude web search on each surface

Surface How to turn it on Limits Cost
claude.ai web and desktop app + > Web search, or nothing to do in the new Claude experience. Team and Enterprise need an Owner to enable it first Counts toward your plan’s usage limits Included in every plan, Free to Enterprise
Research (claude.ai) + > Research, with web search on; /deep-research in the new experience Paid plans only; uses limits faster Included in Pro, Max, Ultra, Team, Enterprise
Claude Code Built in. Approve the first WebSearch prompt, or add an allow rule 200 searches per interactive session, refilling about 100 an hour Part of Claude Code usage; no separate price published
Claude API Add web_search_20260318 (or web_search_20250305) to tools max_uses per turn; organization rate limit $10 per 1,000 searches plus tokens; failed searches not billed
API web fetch Add web_fetch_20260318 to tools No JavaScript rendering; URL must already be in the conversation No extra charge beyond tokens
MCP search server Custom connector in claude.ai, claude_desktop_config.json, or claude mcp add Set by the server Set by the server’s maker

How to enable web search in Claude (claude.ai, desktop and mobile)

Anthropic’s help article Enable and use web search, updated November 9, 2026, gives these steps for a chat:

  1. Click the + button in the lower left corner of the chat window.
  2. Find Web search in the dropdown and click it.
  3. A checkmark appears next to Web search when it is on. Click it again to turn it off.

On a Team or Enterprise plan, an Owner or Primary Owner must first enable web search for the whole workspace in Organization settings > Capabilities. After that, any member can switch it on in a chat.

The new Claude experience, which merges chat and Cowork into one conversation, removes the switch. Anthropic’s article on the new experience says: “There’s no web search toggle. Claude searches the web when it helps.” It is rolling out in stages to Pro, Max and Ultra on web, desktop and mobile. If your message box still shows separate “Chat” and “Cowork” options, you have the older layout and the + menu steps above apply.

Either way, Claude decides when a question needs current information. To make sure it searches, put “Search the web” or “Use web search” in the prompt; you can also tell it not to. With web search on, Claude can also read a page you paste a link to (web fetch), and it may use your location, inferred from your IP address, for local questions. Searches and fetches count toward usage limits, and on a Free plan a long article pasted as a link can use a large share of them.

Research vs web search in Claude

Web search is a few searches inside a normal reply. Research is a longer job: Anthropic describes it as suited to “five or more tool calls over 1-3 minutes” that end in a report built from many sources. Research needs web search turned on, is limited to paid plans (Pro, Max, Ultra, Team and Enterprise), and can also read your connected tools such as Google Workspace. Start it from + > Research, or type /deep-research in the new experience. On Claude Mobile, Research searches the web only and skips your connectors without saying so. Both draw from the same usage limits, and Research uses them faster. Claude Research vs Hyperresearch compares Research with a paid report service.

Claude Code can search the web. It ships two tools:

  • WebSearch runs a query against Anthropic’s web search backend and returns result titles and URLs. One call may run up to eight backend searches. It does not read the pages.
  • WebFetch reads one URL. It converts the page to Markdown and runs your prompt against it in a separate model call, so Claude gets an extract, not the raw page. The docs call this “lossy by design”. It reads up to 100,000 characters per call, caches each URL for 15 minutes, and refuses localhost and hostnames without a dot.

Both ask for permission. The first WebSearch prompt can be approved permanently for the repository, and each WebFetch domain can be approved separately. To skip the prompts, add allow rules to .claude/settings.json (project) or ~/.claude/settings.json (every project):

{
"permissions": {
"allow": ["WebSearch", "WebFetch(domain:docs.python.org)"]
}
}

WebSearch takes no specifier: a bare WebSearch in allow or deny is the only form. To stop Claude Code from searching, put "WebSearch" in deny. The search backend cannot be changed; the docs say to add an MCP server with a search tool if you want a different one.

An interactive session has a limit of 200 WebSearch calls, shared with subagents. It refills at about 100 calls an hour on v2.1.290 and later, and /clear resets it. To raise it, set CLAUDE_CODE_MAX_WEB_SEARCHES_PER_SESSION (for example to 500); CLAUDE_CODE_WEB_SEARCH_REFILLS_PER_HOUR changes the refill rate. In claude -p and the Agent SDK the limit applies per turn instead. CLAUDE_CODE_DISABLE_WEB_FETCH=1 turns WebFetch off and leaves WebSearch on.

WebSearch works on the Claude API, Claude Platform on AWS, Claude Models on Google Cloud and Microsoft Foundry. Amazon Bedrock does not expose the server-side search tool, so Claude Code on Bedrock has no built-in search.

Claude web search API

The API’s web search tool is a server tool: you add it to tools, Claude decides when to search, the API runs the searches, and the answer comes back with citations. Three versions are current:

  • web_search_20250305: basic search.
  • web_search_20260209: adds dynamic filtering, where Claude writes code to filter results before they reach the context window.
  • web_search_20260318: adds response_inclusion for agent workflows.

Dynamic filtering needs Claude 4.6 or later. On a model that cannot call tools from code, set "allowed_callers": ["direct"] or the request fails with a 400. Claude Models on Google Cloud (Google managed) and Azure-hosted Microsoft Foundry offer only web_search_20250305.

import anthropic
client = anthropic.Anthropic() # reads ANTHROPIC_API_KEY
response = client.messages.create(
model="claude-opus-5-5",
max_tokens=2048,
messages=[{"role": "user", "content": "What changed in the newest Python release? Cite sources."}],
tools=[{
"type": "web_search_20260318",
"name": "web_search",
"max_uses": 5,
"allowed_domains": ["python.org"],
"user_location": {"type": "approximate", "country": "US"},
}],
)
for block in response.content:
if block.type == "text":
print(block.text)
for c in block.citations or []:
print(" source:", c.url, "|", c.cited_text)
print("searches billed:", response.usage.server_tool_use.web_search_requests)
Terminal window
curl https://api.anthropic.com/v1/messages \
-H "x-api-key: $ANTHROPIC_API_KEY" \
-H "anthropic-version: 2026-10-21" \
-H "content-type: application/json" \
-d '{
"model": "claude-opus-5-5",
"max_tokens": 2048,
"messages": [{"role": "user", "content": "What changed in the newest Python release? Cite sources."}],
"tools": [{"type": "web_search_20260318", "name": "web_search", "max_uses": 5}]
}'

The parameters:

  • max_uses caps searches in one turn. Anthropic says single-fact questions typically take 1 to 3 searches and comparisons 10 or more. Failed searches count against the cap.
  • allowed_domains or blocked_domains, never both (that is a 400). Use bare domains without https://; example.com covers its subdomains, and a path such as example.com/blog is allowed.
  • user_location localizes results: type must be approximate, plus at least one of city, region, country (two-letter code) or timezone.

Each cited text block carries web_search_result_location citations with the url, title, encrypted_index and up to 150 characters of cited_text. Citations are always on for web search. To continue a conversation, send the assistant’s content blocks back unchanged, including each result’s encrypted_content; a missing or edited value fails with a 400. Search errors such as max_uses_exceeded or too_many_requests arrive inside a 200 response as a web_search_tool_result_error. A long turn can stop with pause_turn; send the message back to continue.

Pricing is $10 per 1,000 searches, so one cent a search, plus normal token rates for the results Claude reads, in that turn and in every later turn that carries them. A search that fails is not billed. Web search is on for an organization unless an admin turned it off in the Claude Console, where they can also limit domains.

The web fetch tool (web_fetch_20260318, or web_fetch_20250910 for basic fetch) reads a whole page or PDF at no charge beyond tokens. It only fetches URLs that already appeared in the conversation, does not render JavaScript, and has citations off by default ("citations": {"enabled": true} turns them on). max_content_tokens truncates long pages.

Add a search MCP server to Claude

An MCP server adds tools from outside Anthropic: a search engine of your choice, a fetcher with a real browser, or a data source. Claude’s built-in search is Anthropic’s own tool, not a Google search box, and Claude Code’s backend cannot be swapped, so a search MCP is how you get results from a specific engine or index. Find servers in the official MCP Registry and Anthropic’s connector directory. The MCP project’s own reference servers include Fetch (reads URLs) but no web search server; search servers are published by the companies and developers who run them.

claude.ai and Claude Desktop (remote server). Open Customize > Connectors, click + Add, then Add custom connector, enter a name and the server URL, review the authentication settings, and click Add. Turn it on per chat from + > Connectors. Custom connectors work on every plan; Free accounts get one. On Team and Enterprise an Owner adds it in Organization settings > Connectors first. Claude connects from Anthropic’s cloud, not your machine, so the server must be reachable from the public internet on port 443.

Claude Desktop (local server). Open the config file from Settings (the MCP docs call it the Developer tab, Edit Config), or edit it directly: ~/Library/Application Support/Claude/claude_desktop_config.json on macOS, %APPDATA%\Claude\claude_desktop_config.json on Windows. This adds the reference Fetch server:

{
"mcpServers": {
"fetch": {
"command": "uvx",
"args": ["mcp-server-fetch"]
}
}
}

Quit Claude Desktop completely and restart it to load the file. Local servers run on your computer and are not available in claude.ai. Desktop extensions (.mcpb files) install local servers in one click: Settings > Desktop app, then Manage next to Extensions.

Claude Code. Add a remote server with one command, then authenticate inside a session:

Terminal window
claude mcp add --transport http my-search https://search.example.com/mcp
claude mcp list # shows "! Needs authentication" until you sign in
# then, inside claude: /mcp, select the server, choose Authenticate

A local server takes its launch command after --, for example claude mcp add fetch -- uvx mcp-server-fetch. Add --scope user for every project or --scope project to write a shared .mcp.json. If you add a search MCP to replace the built-in tool, deny WebSearch in settings so Claude uses yours.

The API. The MCP connector lets a Messages API request call a remote MCP server directly. It is in beta, behind the anthropic-beta: mcp-client-2025-11-20 header. If you are building your own agent rather than using Claude’s apps, how to add web search to an AI agent covers the REST, AI SDK and LangChain routes.

Claude web search troubleshooting

Symptom Cause Fix
No Web search item in the + menu Your account has the new Claude experience Nothing to fix: Claude searches when it helps. Ask it to “search the web”
No Web search item on a Team or Enterprise account An Owner has not enabled it Owner or Primary Owner: Organization settings > Capabilities
Claude answers from memory Claude decides when to search Start the prompt with “Search the web”
Research missing or not researching Free plan, web search off, or both Research models turned off for your role Use a paid plan, turn web search on, or ask the admin; prompt “please use the research tool”
Claude Code shows “Did 0 searches” The session hit its 200-search limit; searches then appear as calls that did nothing Wait for the refill, run /clear, or set CLAUDE_CODE_MAX_WEB_SEARCHES_PER_SESSION; run claude update if every search fails
Claude Code has no WebSearch tool Running on Amazon Bedrock, or a WebSearch deny rule Use the Claude API or another supported platform, or remove the rule; or add a search MCP
Claude Code has no WebFetch tool Team or Enterprise policy not loaded, or CLAUDE_CODE_DISABLE_WEB_FETCH set Run /status or claude doctor and check the Organization policy line
API 400 saying web search is not enabled An admin turned it off for the organization Turn it on in Console > Settings > Capabilities
API 400 on the tool definition Both domain lists set, a scheme in a domain, an unsupported country code, or dynamic filtering on a model without code tool calls Use one list, bare domains, a valid ISO code, or "allowed_callers": ["direct"]
API 400 on a follow-up turn encrypted_content or encrypted_index missing or changed Send the assistant blocks back exactly as received
Custom connector will not connect Server is on a private network, behind a VPN, or on a port other than 443 Host it publicly on 443, or allowlist Anthropic’s IP ranges
Results for the wrong country Location comes from your IP in the app In the API, set user_location; in the app, name the place in the prompt

When Claude’s built-in web search is not enough

Built-in search finds public pages and cites them. Some work needs more than that:

  • Paywalled or logged-in pages. Built-in search and fetch work from public pages, so a page behind a login or paywall needs your own access. The API fetcher also skips pages that only exist after JavaScript runs, and refuses URLs that robots.txt blocks. For papers, a legal open-access copy often exists: open-access full text for agents shows how to find one by DOI.
  • Structured data. Search returns pages, and Claude Code’s WebSearch returns only titles and URLs. A question about filings, trial registrations or official statistics is better answered from the source’s own records than from a page that quotes them. The Census API and SEC EDGAR API guides show what direct access looks like.
  • Citations you have to defend. An API citation carries at most 150 characters of cited text, and Claude Code’s WebFetch hands Claude a model-written extract rather than the page. Neither tells you whether the sentence Claude wrote is what the source says. How to verify citations in AI output gives a manual check that catches the common failures.

For those cases, add a research MCP next to the built-in tools. Hyperresearch’s MCP server adds 120+ structured public data sources, such as SEC filings, Census data and PubMed, and checks each citation against a quote from the source it cites; the source list shows what it reads and Connect Hyperresearch to Claude has the setup for claude.ai, Claude Desktop and Claude Code.