MCP Server for Web Search

View as MarkdownOpen in Claude

The Model Context Protocol (MCP) is the emerging standard for giving AI agents and assistants access to tools and data. Any MCP-compatible client — Claude Desktop, Cursor, Windsurf, Zed, or a custom agent you’re building — can connect to any MCP server to pick up new capabilities. No SDK glue code, no custom tool definitions, no per-framework wrappers.

This guide covers how MCP works for web search specifically, why it’s the right way to give an LLM access to the internet, and how to install and configure the You.com MCP server in the clients developers actually use.

TL;DR — MCP is the USB-C port for AI tools. The You.com MCP server is a web search plug that fits it. Install it in Claude, Cursor, or any MCP client, and your assistant can query the live web with structured, citation-ready results.

What MCP is, in one paragraph

Model Context Protocol is an open specification that defines how an LLM client talks to an external tool server. The client announces “here’s what my model can call”; the server announces “here are the tools I expose”; the two communicate over stdio or HTTP using a small, stable JSON-RPC schema. The value is portability: one MCP server works in every MCP-compatible client, and one MCP client works with every MCP server. No bespoke integrations per pair.

For web search, this matters because every agent framework and every assistant historically re-implemented the same web-search tool, slightly differently, in their own SDK. MCP collapses that into one server that every client can use.

Why web search is the highest-value MCP tool

Of the tools you can bolt onto an MCP client, web search punches above its weight. A few reasons:

  • It unlocks every other tool. Most agent tasks start with “figure out what the current state of X is.” File tools, code tools, and API tools all become more useful when the agent can first check the web for context.
  • It removes the training-cutoff ceiling. Without web access, an assistant is bounded by what its model saw months or years ago. With it, yesterday’s news is in scope.
  • It’s the one tool every agent needs. File I/O, database access, and code execution are workload-specific. Web search is universal.

If you’re only going to install one MCP server, a search server is the one with the highest hit rate across tasks.

What a “good” MCP search server looks like

Not all MCP servers are equal. For a search server specifically, four things matter:

  • Structured results, not HTML. The server should return JSON with titles, URLs, and pre-extracted snippets — not a rendered SERP. The LLM can’t parse HTML efficiently.
  • Real index, not scraped SERPs. Servers that scrape Google or Bing break frequently and violate ToS. A server backed by an independent index is stable.
  • Low latency. MCP calls are in the critical path of every agent turn. A p95 above a couple of seconds makes the assistant feel sluggish.
  • Sensible tool surface. One or two well-named tools beat ten overlapping ones. MCP clients pass every tool description to the model on every turn, so a bloated tool list taxes the context window.

The You.com MCP server is built against all four. It exposes a small set of tools backed by the You.com Search and Contents APIs — the same independent index that powers the rest of the platform.

What the server exposes

The You.com MCP server exposes a focused set of tools. When an MCP client connects, it sees this tool list:

  • you-search — web and news search with structured snippets. Input: query (string), plus optional filters. Output: list of results with title, url, and pre-extracted snippets.
  • you-contents — extract the cleaned page content from a URL in Markdown or HTML format. Input: url (string). Output: full page content ready for LLM consumption.
  • you-research — multi-step research for deeper questions. Input: query (string). Output: synthesized, citation-backed report with lite, standard, deep, and exhaustive effort levels.

That’s the full surface. Three tools is enough to cover the full grounding → citation → deep-dive loop inside an assistant.

The remote server at https://api.you.com/mcp is the fastest path — no install, always up to date. Authenticate with either a bearer API key or OAuth 2.1 (any MCP client that implements the authorization flow can connect without credentials and the flow starts automatically).

1{
2 "mcpServers": {
3 "ydc-server": {
4 "type": "http",
5 "url": "https://api.you.com/mcp",
6 "headers": {
7 "Authorization": "Bearer <your-api-key>"
8 }
9 }
10 }
11}

Get an API key at you.com/platform.

Install: Claude Desktop (local NPM package)

Claude Desktop is the reference MCP client. If you prefer a local server — for offline use, self-hosting, or air-gapped environments — install via the NPM package. Configuration lives in claude_desktop_config.json.

  • macOS path: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows path: %APPDATA%\Claude\claude_desktop_config.json

Add the You.com server to the mcpServers block:

1{
2 "mcpServers": {
3 "ydc-server": {
4 "command": "npx",
5 "args": ["-y", "@youdotcom-oss/mcp"],
6 "env": {
7 "YDC_API_KEY": "<your-api-key>"
8 }
9 }
10 }
11}

Restart Claude Desktop. The you-search tool will appear in the tool picker, and Claude will call it automatically when a question needs fresh information.

Install: Cursor

Cursor supports MCP through its settings UI or a config file at ~/.cursor/mcp.json. The remote server is the recommended setup — paste this, without the type field:

1{
2 "mcpServers": {
3 "ydc-server": {
4 "url": "https://api.you.com/mcp",
5 "headers": {
6 "Authorization": "Bearer <your-api-key>"
7 }
8 }
9 }
10}

After saving, restart Cursor. The search tool is available inside Cursor’s agent mode — useful for grounding code suggestions in current documentation (new library versions, recent RFCs, fresh Stack Overflow answers).

Install: custom MCP client

If you’re building your own MCP client, connect to the server over stdio using any MCP client library. Here’s a Python example using the official mcp package:

1import asyncio
2import os
3from mcp import ClientSession, StdioServerParameters
4from mcp.client.stdio import stdio_client
5
6server_params = StdioServerParameters(
7 command="npx",
8 args=["-y", "@youdotcom-oss/mcp"],
9 env={"YDC_API_KEY": os.environ["YDC_API_KEY"]},
10)
11
12async def main():
13 async with stdio_client(server_params) as (read, write):
14 async with ClientSession(read, write) as session:
15 await session.initialize()
16
17 # List available tools
18 tools = await session.list_tools()
19 print([t.name for t in tools.tools])
20 # → ['you-search', 'you-contents', 'you-research']
21
22 # Call the search tool
23 result = await session.call_tool(
24 "you-search",
25 arguments={"query": "latest transformer architecture papers"},
26 )
27 for block in result.content:
28 print(block)
29
30asyncio.run(main())

That’s the full pattern. The MCP client library handles the JSON-RPC transport; you just call tools by name.

Install: HTTP transport (for hosted clients)

For MCP clients that prefer HTTP over stdio — hosted agents, serverless environments, browser-based clients — the You.com MCP server supports streamable HTTP at:

https://api.you.com/mcp

Authenticate with a standard bearer header:

Authorization: Bearer <your-api-key>

Point any MCP-over-HTTP client at that URL and it’ll discover and call tools identically to the stdio transport.

What a typical call looks like

Once installed, the MCP client handles invocation. Under the hood, a you-search call looks like this on the wire.

Request (JSON-RPC):

1{
2 "jsonrpc": "2.0",
3 "id": 1,
4 "method": "tools/call",
5 "params": {
6 "name": "you-search",
7 "arguments": {
8 "query": "openai gpt-5 release date"
9 }
10 }
11}

Response:

1{
2 "jsonrpc": "2.0",
3 "id": 1,
4 "result": {
5 "content": [
6 {
7 "type": "text",
8 "text": "[{\"title\": \"...\", \"url\": \"...\", \"snippets\": [\"...\"]}]"
9 }
10 ]
11 }
12}

The text block is a JSON-encoded list of hits — the same structure the Search API returns directly. MCP clients parse that and hand the results to the model as an observation.

Production patterns

Four upgrades worth doing once the server is installed:

Scope the tool description. MCP clients pass every tool description to the model on every turn. If you’re running multiple MCP servers, review the descriptions so the model picks the right tool. The search server’s default description is tuned for this, but custom builds may need trimming.

Cache identical queries. Agents re-ask the same subquestions. A short-TTL cache at the server layer (or in the client) cuts repeated cost significantly on research-style tasks.

Combine with you-contents for depth. The pattern that works: you-search to discover relevant pages, then you-contents on the top result for full-page context when snippets aren’t enough. This mirrors how a human researcher moves from SERP to article.

Disable tools you don’t need. On HTTP transport, send X-Disable-Tools: you-research,you-contents (comma-separated) to hide tools from the session. Smaller tool lists mean smaller prompts and faster tool selection.

MCP vs. framework-native tools

Most agent frameworks (LangChain, Vercel AI SDK, smolagents, Agno) also support a framework-native web search tool. When do you use MCP instead?

Use framework-native when…Use MCP when…
Building a single-framework agentBuilding across multiple frameworks
Deep SDK integration neededTool portability matters
Single-process, low-latency stdioNeed a hosted client (Claude Desktop, Cursor)
Python/TS onlyMulti-language or polyglot agents

Both options use the same underlying Search API. MCP is the better choice when portability across clients matters, or when the end user — not the developer — is the one installing the tool (which is the whole Claude Desktop / Cursor story).

Why You.com for MCP search specifically

Three things that matter for this use case:

  • Independent index. The server isn’t a scraper wrapping Google. It’s backed by the You.com crawler and index, so it doesn’t break when upstream engines change their terms.
  • LLM-native response shape. Results come back as structured snippets with URLs — exactly the shape MCP clients hand to the model.
  • Built for the ecosystem. You.com helped shape the early MCP search patterns. The server is designed to play nicely with Claude Desktop, Cursor, and any new MCP client that ships.

Next steps