Guide
How to add a custom MCP server to Grok
Grok can call tools on any MCP server you give it, through custom connectors. Here are the steps, what Grok needs from the server, why sign-in fails when it does, and how it differs from Grok Bot and the xAI API.
From xAI’s connector docs, checked October 21, 2026.
Add the connector
- Go to grok.com/connectors.
- Choose New Connector, then Custom.
- Enter the server’s URL, often ending in
/mcp. - Complete the server’s sign-in when Grok sends you there.
- In a new chat, ask something only that server can answer, and check the answer.
Grok reads the server’s list of tools and uses them when a question calls for it. xAI’s docs say connectors are available to all Grok users; some guides say custom connectors need a paid plan, so if Custom is missing, check your plan. On Grok Business and Enterprise, an admin provisions connectors in the xAI console before members can use them.
What the server needs
- A public HTTPS URL. Grok connects from xAI’s servers and rejects localhost and private addresses.
- A transport Grok speaks: Streamable HTTP (current) or SSE (older).
- Standard MCP sign-in, if it needs one: OAuth with PKCE, where Grok registers itself through dynamic client registration and comes back to an https callback on grok.com.
Servers on your own machine
A server running on your laptop needs a public address. xAI’s tunneling guide suggests a Cloudflare quick tunnel for Streamable HTTP servers and ngrok for SSE, since Cloudflare quick tunnels don’t carry server-sent events. Free tunnel URLs usually change on restart, which means removing and re-adding the connector, and Grok’s tool calls fail whenever your machine is asleep.
When sign-in fails
- “redirect_uri not allowed” or a 4xx at registration: the server rejects Grok’s https callback. Its OAuth settings need to allow dynamic registration with https callbacks, not just localhost or a fixed list of apps. Only the server’s owner can change that.
- Sign-in works, no tools: check the URL path and that the server answers on the transport Grok expects.
- Works, then stops: the tunnel URL changed, or the server’s tokens expired without refresh. Remove and re-add the connector.
- Team members can’t see it: on Business and Enterprise, it has to be provisioned by an admin.
Grok Bot and the API
Grok Bot is a separate, always-on agent that adds MCP servers when you ask it in chat, on its own cloud computer, with OAuth sign-in. Its custom-server sign-in has had open bug reports this fall, so if a server works at grok.com but not in Grok Bot, that’s likely why.
The xAI API lets developers hand a remote MCP server to Grok models as a tool. That’s for apps you build, not for chatting at grok.com.
A worked example
Cachejay is a memory server: it records your workday on your Mac (screen text, calls, coding-agent sessions) and lets AI apps search it. Its URL is https://cachejay.com/mcp, and it uses the sign-in Grok expects. In the Cachejay menu, Connect AI Apps › Grok… copies the URL and opens grok.com/connectors; paste it under New Connector › Custom, sign in, and ask “what did I agree to on calls this week?”. Full steps on the Grok page. For what a memory server is, see what is an MCP memory server, and for ChatGPT’s equivalent, adding an MCP server to ChatGPT.