ChatGPT WebSearch MCP
Provides access to OpenAI's ChatGPT API with web search capabilities, supporting various models including reasoning models with configurable effort levels, temperature settings, and streaming options.
Click on "Install 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., "@ChatGPT WebSearch MCPexplain quantum computing in simple terms using web search"
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.
ChatGPT WebSearch MCP
A local MCP stdio server that provides access to the OpenAI (ChatGPT) API for Claude Code and other MCP clients. Supports models with web search capabilities.
Usage
Claude Code
$ claude mcp add chatgpt-websearch \
-s user \ # If you omit this line, it will be installed in the project scope
-e OPENAI_API_KEY=your-api-key \
-- npx @nekobato/chatgpt-websearch-mcpOr configure in settings
{
"mcpServers": {
"chatgpt-websearch": {
"command": "npx",
"args": ["@nekobato/chatgpt-websearch-mcp"],
"env": {
"OPENAI_API_KEY": "your-api-key",
...
},
},
},
}Environment Variables
The following environment variables can be used to set default values:
OPENAI_API_KEY(required): Your OpenAI API keyOPENAI_DEFAULT_MODEL(optional): Default model to use (default: gpt-5)REASONING_EFFORT(optional): Default reasoning effort level for reasoning models (minimal|low|medium|high)SEARCH_CONTEXT_SIZE(optional): Default verbosity level (low|medium|high)OPENAI_MAX_RETRIES(optional): Default maximum retry attempts (default: 3)OPENAI_API_TIMEOUT(optional): Default API timeout in milliseconds. If not set, auto-adjusts based on effort level:minimal/low: 60000 (1 minute)medium: 120000 (2 minutes)high: 300000 (5 minutes)
Related MCP server: GPT-5 MCP Server
API
MCP Tools
ask_chatgpt: Send a prompt to ChatGPT and receive a responseprompt(required): The prompt to sendmodel(optional): The model to use (default: from OPENAI_DEFAULT_MODEL env var or gpt-5)system(optional): System prompt to set context and behaviortemperature(optional): Temperature for response generation (0-2, default: 0.7) - Not available for reasoning modelseffort(optional): Reasoning effort level (minimal|low|medium|high, default: from REASONING_EFFORT env var) - For reasoning models onlyverbosity(optional): Output verbosity (low|medium|high, default: from SEARCH_CONTEXT_SIZE env var) - For reasoning models onlymaxTokens(optional): Maximum output tokensmaxRetries(optional): Maximum API retry attempts (default: from OPENAI_MAX_RETRIES env var or 3)timeoutMs(optional): Request timeout in milliseconds. Auto-adjusts based on effort level (high=300s, medium=120s, low/minimal=60s)useStreaming(optional): Force streaming mode to prevent timeouts. Auto-enabled for medium/high effort reasoning models
Development
Requirements
Node.js 22+
An OpenAI API key in
OPENAI_API_KEY
Commands
# Install dependencies
pnpm install
# Run in development mode
pnpm dev
# Build for production
pnpm build
# Run tests
pnpm test
# Lint code
pnpm lint
# Format code
pnpm formatLicense
MIT License
Available Tools
1 toolask_chatgptA
Ask ChatGPT a question and get a response. Supports both regular models (with temperature) and reasoning models (with effort/verbosity).
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | The prompt to send to ChatGPT | |
| model | No | The model to use (default: from OPENAI_DEFAULT_MODEL env var or gpt-5). Unless specified by the user, you should not set this model parameter. Supported models: gpt-5, gpt-5-mini, gpt-5-nano, o3, o3-pro, o4-mini, gpt-4.1, gpt-4.1-mini | gpt-5 |
| system | No | System prompt to set context and behavior for the AI | |
| temperature | No | Temperature for response generation (0-2). Not available for reasoning models (gpt-5, o1, o3, etc.) | |
| effort | No | Reasoning effort level: minimal, low, medium, high (default: from REASONING_EFFORT env var). For reasoning models only. | |
| verbosity | No | Output verbosity level: low, medium, high (default: from VERBOSITY env var). For reasoning models only. | |
| searchContextSize | No | Search context size: low, medium, high (default: from SEARCH_CONTEXT_SIZE env var). For reasoning models only. | |
| maxTokens | No | Maximum number of output tokens | |
| maxRetries | No | Maximum number of API retry attempts (default: from OPENAI_MAX_RETRIES env var or 3) | |
| timeoutMs | No | Request timeout in milliseconds. Auto-adjusts based on effort level: high=300s, medium=120s, low/minimal=60s. Can be overridden with OPENAI_API_TIMEOUT env var. | |
| useStreaming | No | Force streaming mode to prevent timeouts during long reasoning tasks. Defaults to auto (true for medium/high effort reasoning models). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Without annotations, the description carries full burden. It mentions the core behavior (ask question, get response) and model types, but does not disclose potential side effects (e.g., cost, latency) or authentication requirements. The schema provides additional details like streaming and timeouts, but the description itself is minimal.
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?
Two sentences that front-load the core purpose and then provide a succinct differentiation of model types. No unnecessary words.
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?
The description covers the essential purpose and model distinction, but given 11 parameters and no output schema, it could mention the return format (text response) and streaming behavior. It is mostly complete, leaving some details to the schema.
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?
With 100% schema coverage, the baseline is 3. The description adds value by grouping parameters: regular models use temperature, reasoning models use effort/verbosity. This contextual guidance helps the agent select appropriate parameters.
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 asks ChatGPT a question and gets a response. It distinguishes between regular and reasoning models, which aligns with the model parameter options.
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?
The description provides context on when to use regular models (with temperature) vs reasoning models (with effort/verbosity). However, it lacks explicit guidance on when not to use this tool, though no siblings exist to compare.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
TDQS
With only one tool, there is no possibility of confusion between tools.
A single tool means naming is trivially consistent.
A single tool is far too few for a server named 'WebSearch MCP'; it suggests a mismatch between server purpose and tool surface.
The server only offers ask_chatgpt, lacking dedicated web search, scraping, or any other relevant operations, making it severely incomplete.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Use AI models for chat, image, and video generation from Claude Code and other MCP hosts.
Search your AI chat history (ChatGPT, Claude, Codex) from any MCP client. Remote, private, read-only
Talk to your public-facing AI from any MCP client — Claude, ChatGPT, Cursor, Cline, Windsurf.
One API key for 6 AI models. Pay-per-use. MCP protocol support with web search.
Related MCP Servers
- AlicenseCqualityDmaintenanceEnables integration with OpenAI models through the MCP protocol, supporting concise and detailed responses for use with Claude Desktop.13MIT
- FlicenseCqualityDmaintenanceEnables GPT-5 inference via OpenAI API with configurable reasoning effort, verbosity levels, and optional web search integration. Supports per-call parameter overrides for flexible AI model interactions through MCP.1
- FlicenseNot gradedqualityNot gradedmaintenanceEnables Claude and other MCP-compatible tools to communicate with OpenAI's GPT models (GPT-5, GPT-5-mini, o3) with conversation history and session management. Features advanced controls like reasoning effort settings, token tracking, and parallel conversation sessions for efficient AI workflows.10
- FlicenseBqualityDmaintenanceEnables interaction with OpenAI's Chat Completion and Assistants APIs, supporting assistant management, file operations, and direct queries to GPT models through standardized MCP tools.92
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/nekobato/chatgpt-websearch-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server