grok-native-search-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@grok-native-search-mcpsearch the web for today's top tech headlines"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Grok Native Search MCP
A minimal stdio MCP Server providing three read-only tools:
web_search(query): Grok native Web Searchx_search(query): Grok native X Searchweb_fetch(url): Jina Reader web page to Markdown
Search always uses grok-4.6, reasoning.effort: low, and max_turns: 1. Complementary searches may run in parallel within a single turn, stopping once enough first-hand evidence is found, and expanding scope only when evidence is missing or conflicting. Tool responses are not parsed or rewritten; they are returned directly as MCP text.
Tool routing: use web_fetch for known URLs or when page content needs verification; use x_search for X posts, accounts, threads, and trends; use web_search for other web-wide searches without a specific URL. After a search returns an external URL that needs verification, continue by calling web_fetch.
Environment Variables
Variable | Purpose |
| API Key for xAI or a compatible gateway |
| Optional, Responses API base URL; defaults to |
| Jina Reader API Key |
| Optional, environment proxy configuration used only for Jina Reader requests |
Related MCP server: grok-build-plugin
Start with npx
npx -y grok-native-search-mcp@latestCodex Configuration
[mcp_servers.grok_native_search]
command = "npx"
args = ["-y", "grok-native-search-mcp@latest"]
env_vars = ["XAI_API_KEY", "JINA_API_KEY", "HTTP_PROXY", "HTTPS_PROXY", "NO_PROXY"]Restart Codex after configuration.
Local Development
npm install
npm testAvailable Tools
3 toolsweb_fetchARead-only
Use this when an exact HTTP(S) URL is known, including URLs returned by web_search or x_search, and the task is to read, quote, summarize, or verify page text. Prefer it over Browser, curl, or shell when no login, click, form interaction, or visual inspection is required. Do not use it to discover URLs. Returns raw Markdown from Jina Reader.
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | Exact HTTP(S) URL to read; pass source URLs from web_search or x_search unchanged |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already supply readOnlyHint beyond which the description adds meaningful context: it returns 'raw Markdown from Jina Reader' and clarifies the tool is non-interactive (no login, click, form, or visual inspection). This disclosure exceeds the annotation and helps the agent calibrate expectations. A 4 reflects the extra value without being exhaustive.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences, zero fluff. The core purpose is front-loaded, followed by usage exclusions and a note on return format. Every sentence serves a purpose—no repetition or filler.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a single-parameter read-only tool, the description completely covers what the agent needs: when to invoke it, what it returns, and what it is not for. No output schema is present, but the return type is disclosed. Nothing essential is missing.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The sole parameter (url) is fully documented in the schema with a detailed description ('Exact HTTP(S) URL... pass source URLs unchanged'). Schema coverage is 100%, so the description does not need to add parameter info; the minimal restatement adds no extra meaning beyond the schema. Baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States a specific verb+resource: 'read, quote, summarize, or verify page text' from an exact HTTP(S) URL. It distinguishes itself from siblings web_search and x_search by clarifying it consumes their URLs, and differentiates from Browser/curl/shell by its non-interactive read-only role.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly defines when to use (exact URL known, text-read task) and when not (URL discovery, need login/click/form/visual). Names alternatives (Browser, curl, shell) and states preference conditions. Provides clear routing guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
web_searchARead-only
Use this when no exact URL is known and current information must be discovered across the public web. Complementary queries may run in parallel when multiple evidence lanes are needed. Stop after an authoritative source answers the question; deepen only for missing or conflicting evidence. For X-only content use x_search. After finding a page whose contents must be verified, call web_fetch with its exact URL. Returns the raw xAI Responses API body.
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | The question or search query to investigate |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true, so the bar is lower. The description adds useful behavioral context beyond that: complementary queries may run in parallel, stopping after an authoritative source, and the tool returns the raw xAI Responses API body. This gives the agent a clear picture of execution behavior and output format without contradicting the read-only hint.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single paragraph with five sentences, each serving a distinct purpose: usage trigger, parallel query allowance, stop condition, sibling differentiation, and follow-up. There is no fluff, and the most critical information is front-loaded. It is slightly dense but each clause earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (one parameter), no output schema, and read-only annotation, the description covers all essential aspects: when to use, alternatives, follow-up actions, operational heuristics, and the return format. An agent can confidently invoke it correctly without additional context.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so the parameter 'query' is already well-described as 'The question or search query to investigate'. The description does not add additional syntax, formatting, or examples beyond the schema. It mentions parallel queries, but that is not specific to the parameter's meaning. Given full schema coverage, the baseline of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: discovering current information across the public web when no exact URL is known. It uses a specific verb ('discover') and resource ('public web'), and distinguishes itself from sibling tools (x_search for X-only content, web_fetch for page verification). This leaves no ambiguity about what web_search does.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly states when to use the tool ('when no exact URL is known and current information must be discovered'), when not to (use x_search for X-only content), and the follow-up action (call web_fetch after finding a page to verify). It also provides operational guidance on parallel queries and stop conditions, making the decision tree fully transparent.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
x_searchARead-only
Use this for current X posts, accounts, threads, replies, and trends. Prefer it over web_search for X content. Complementary X queries may run in parallel. Stop when the requested official post or account result is found; deepen only if evidence is missing or conflicting. If a post links to an external page that must be read, call web_fetch with that URL. Returns the raw xAI Responses API body.
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | The question or search query to investigate |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations only declare readOnlyHint=true; the description adds meaningful behavioral context beyond that: complementary queries may run in parallel, stopping/termination behavior, conditions for deepening, and the return format ('raw xAI Responses API body'). No contradiction with the read-only annotation.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Five functional sentences with the primary purpose front-loaded and every sentence earning its place — scope, routing, stopping, deepening, and fetch delegation. Slightly dense but appropriate given the multiple behavioral rules it must convey.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Comprehensive for a search tool covering multiple content types with parallelism, termination, and delegation rules. With no output schema present, the description still discloses the raw response body. Nothing an agent needs to invoke this correctly is missing.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% since the query parameter is fully documented ('The question or search query to investigate'). The description adds little parameter-specific detail beyond the schema, so the baseline of 3 applies. Parallel-execution hints imply query handling but don't add syntax or format value.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific resource (X posts, accounts, threads, replies, trends) with a clear search intent, and explicitly routes around siblings by saying 'Prefer it over web_search for X content.' An agent can distinguish x_search from web_search and web_fetch without opening schemas.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides explicit when-to-use scope (X content), preference over web_search, a stopping condition ('Stop when the requested official post or account result is found'), a deepen-only-on-conflict rule, parallel-execution guidance, and explicit delegation to web_fetch for external pages. This is model guidance with clear exclusions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
3 tool updates
v1.0.3- First observed
web_fetch - First observed
web_search - First observed
x_search
TDQS
Scored across 3 tools
Each tool has a clearly distinct purpose: web_search for general web discovery, x_search specifically for X content, and web_fetch for retrieving a known URL. The descriptions explicitly cross-reference each other (e.g., web_search notes 'For X-only content use x_search'), leaving no ambiguity about which tool to select.
All three tool names follow a consistent `[source]_[action]` pattern: web_search, x_search, web_fetch. The naming convention is uniform, predictable, and immediately conveys scope (web vs. x) and operation (search vs. fetch).
With only 3 tools, the server is tightly scoped for its purpose: general web search, X-specific search, and URL fetching. This is well within the ideal 3–15 range and every tool earns its place; adding more would likely introduce redundancy.
The surface covers the full lifecycle of a search task: discover sources (web_search, x_search) and then retrieve/verify content (web_fetch). The tools explicitly reference each other to create a complete workflow, with no obvious gaps for the stated domain.
Maintenance
Related MCP Connectors
Live AI-native web search with citations. One tool for every MCP client. Flat per-request pricing.
Search the agentic web. 4,100+ sites, 11 tools incl. check_url + verify_mcp for probe-before-use.
Enable AI assistants to perform web searches using Perplexity's Sonar Pro.
Web search, scraping, RAG answers with citations, and translation as MCP tools.
Related MCP Servers
- AlicenseAqualityDmaintenanceEnables real-time web search via DeepSeek's search-enhanced dialogue, providing search results as answers through MCP tools.1MIT
- AlicenseNot gradedqualityBmaintenanceLive X (Twitter) and web search for any coding agent through your existing Grok subscription. Exposes a grok_search MCP tool, so no X API key or X developer account is needed.21 npm28Apache 2.0
- AlicenseAqualityBmaintenanceEnables web search and web fetch operations using Ollama's hosted APIs, allowing MCP clients to search the web and retrieve page content.2MIT
- AlicenseDqualityDmaintenanceEnables Google web search via MCP, compatible with gemini-cli's google_web_search tool.25 npmApache 2.0