Neon Serverless Postgres MCP
Neon's hosted MCP (mcp.neon.tech) exposes the open-source neondatabase/mcp-server-neon toolset remotely: projects, branches, schemas and SQL execution with OAuth.
- Provider
- Neon โ
- Source
- https://github.com/neondatabase/mcp-server-neon โ
- Categories
- ๐๏ธ Databases & Backend-as-a-Service
ไธญๆ็ฎไป
Neon ๅฎๆน่ฟ็จ MCP ๆๅกๅจ๏ผServerless Postgres๏ผใ้่ฟ SSE ไธ OAuth๏ผAI ไปฃ็ๅฏ็ฎก็้กน็ฎใๅๅปบๅๆฏๅนถๆง่ก SQLใ
Or add to ~/.cursor/mcp.json:
{
"mcpServers": {
"neon": {
"url": "https://mcp.neon.tech/sse"
}
}
}claude mcp add --transport sse neon https://mcp.neon.tech/sse
Or add to .vscode/mcp.json:
{
"servers": {
"neon": {
"type": "sse",
"url": "https://mcp.neon.tech/sse"
}
}
}- Open Settings โ Connectors (Integrations) โ Add Custom Connector.
- Paste the endpoint URL:
https://mcp.neon.tech/sse - Complete the browser OAuth 2.1 login flow when prompted.
Bridge the remote endpoint into stdio with mcp-remote in claude_desktop_config.json:
{
"mcpServers": {
"neon": {
"command": "npx",
"args": [
"-y",
"mcp-remote",
"https://mcp.neon.tech/sse"
]
}
}
}Add to ~/.codeium/windsurf/mcp_config.json:
{
"mcpServers": {
"neon": {
"serverUrl": "https://mcp.neon.tech/sse"
}
}
}๐งฐ Tools exposed by Neon MCP (4)
| Tool | Safety | Description | Parameters |
|---|---|---|---|
| list_projects | ๐ข Read | List Neon projects accessible to the authorized account. | โ |
| run_sql | ๐ Write | Execute SQL against a Neon database. Can modify data โ review statements carefully. | projectId*: stringdatabaseName: stringsql*: string |
| create_branch | ๐ Write | Create a new branch in a Neon project. | projectId*: stringbranchName: string |
| describe_table_schema | ๐ข Read | Describe the schema of a table in a Neon database. | projectId*: stringdatabaseName: stringtableName*: string |
๐ OAuth 2.1 & Security
- Auth type
- OAuth 2.1
- Dynamic Client Registration
- โ Supported
- PKCE S256
- โ Supported
- Protected resource metadata
- https://mcp.neon.tech/.well-known/oauth-protected-resource (expected location)
๐งฉ Recommended Agent Skills
๐ Guide
Neon MCP โ Remote MCP Server
Neon's remote MCP is the hosted twin of the open-source mcp-server-neon: list projects, create database branches, describe schemas and run SQL โ all authorized through Neon OAuth. Neon's branching model makes it friendly to agents: have them create a branch, run migrations there, and merge when green.
Endpoint & Transport
- Endpoint URL:
https://mcp.neon.tech/sse - Transport: HTTP+SSE (legacy SSE transport)
Authentication
Neon MCP uses OAuth 2.1 โ the first request returns a 401 Unauthorized challenge with a WWW-Authenticate header pointing at the authorization metadata. Compliant clients (Cursor, Claude, VS Code, ChatGPT) handle the whole flow โ PKCE and Dynamic Client Registration, so no manual client setup is needed โ and simply open a browser consent screen.
Available Tools (4)
| Tool | Safety | Description |
|---|---|---|
list_projects |
read | List Neon projects accessible to the authorized account. |
run_sql |
write | Execute SQL against a Neon database. Can modify data โ review statements carefully. |
create_branch |
write | Create a new branch in a Neon project. |
describe_table_schema |
read | Describe the schema of a table in a Neon database. |
Connect in 30 Seconds
Claude Code โ one command:
claude mcp add --transport sse neon https://mcp.neon.tech/sse
Cursor โ add to ~/.cursor/mcp.json:
{ "mcpServers": { "neon": { "url": "https://mcp.neon.tech/sse" } } }
VS Code โ add to .vscode/mcp.json:
{ "servers": { "neon": { "type": "sse", "url": "https://mcp.neon.tech/sse" } } }
Claude Desktop & stdio clients โ bridge with mcp-remote:
{ "mcpServers": { "neon": { "command": "npx", "args": ["-y", "mcp-remote", "https://mcp.neon.tech/sse"] } } }
On first connect your client opens a browser OAuth consent screen โ approve it and tools become available immediately.
Troubleshooting
- 401 Unauthorized on connect โ that's expected; the server is OAuth-protected. Let your client complete the browser consent flow, or inspect the endpoint in our OAuth debugger to see the exact
WWW-Authenticatechallenge. - Client says "unsupported transport" โ this endpoint only speaks the legacy SSE transport. Use a client with SSE support (Claude Code:
claude mcp add --transport sse) or bridge it withmcp-remote. - "Session expired" / stale
Mcp-Session-Idโ just re-sendinitialize; stateless clients can ignore session headers entirely. - SSE transport โ use
--transport sseor an SSE-capable client. - run_sql executes real statements โ point agents at branches rather than production.
๐ How to Connect
- Copy the Neon MCP endpoint URLThe remote endpoint is https://mcp.neon.tech/sse.
- Add it to your MCP clientClaude Code:
claude mcp add --transport sse neon https://mcp.neon.tech/sse. Cursor: add"neon": { "url": "https://mcp.neon.tech/sse" }undermcpServersin ~/.cursor/mcp.json. Other clients work similarly. - Complete the OAuth consentOn first connection your client opens a Neon consent screen in the browser. Approve it to grant access; the token is stored by the client and refreshed automatically.
- Verify with the online inspectorPaste https://mcp.neon.tech/sse into remotemcp.net/inspector, run initialize and tools/list, and confirm Neon MCP's 4 tools respond.
โ FAQ
What is the Neon MCP remote MCP endpoint?
The primary endpoint is https://mcp.neon.tech/sse. It is an official first-party server operated by Neon, speaking the HTTP+SSE (legacy SSE transport) transport.
How do I authenticate with Neon MCP?
Neon MCP uses OAuth 2.1. When your client first connects it receives a 401 challenge, discovers the authorization server via RFC 9728 metadata, and opens a browser consent screen. Dynamic Client Registration is supported, so compliant clients register themselves automatically.
I'm getting a 401 Unauthorized from Neon MCP โ what's wrong?
A 401 means your client hasn't completed (or has lost) the OAuth authorization. Remove and re-add the server in your client to restart the consent flow, and check that your browser session can reach the provider's login page. If the 401 arrives without a WWW-Authenticate header, run it through our OAuth debugger to see what's missing.
Which MCP clients work with Neon MCP?
Any client that supports remote MCP servers: Cursor, Claude Code (`claude mcp add --transport sse neon https://mcp.neon.tech/sse`), VS Code Copilot, ChatGPT connectors, Windsurf, and Claude Desktop via the `mcp-remote` bridge. Note this server only offers the SSE transport, so the client must support SSE.
What tools does Neon MCP expose?
4 tools are cataloged in this directory โ including `list_projects`, `run_sql`, `create_branch` and more. Use our online inspector to fetch the live tool list straight from the endpoint.
๐ Connect Guides
๐ Embed Status Badge in README
Related Servers
Supabase's hosted MCP server for your projects and databases. Agents can run SQL, apply migrations and generate TypeScript types with OAuth-scoped access.