For the complete documentation index, see llms.txt. This page is also available as Markdown.

Use with Claude Desktop

Connect Claude Desktop to PostgreSQL through pREST’s read-only MCP tools. Claude can discover schemas and query data via your running pREST instance.

pREST speaks MCP over HTTP at /_mcp. Claude Desktop launches stdio MCP servers, so you need the official prest-mcp adapter as a bridge.

Requires pREST v2.1.0+.


Prerequisites

  • pREST running locally or on a reachable host (see Get pREST)

  • prest-mcp installed (Homebrew, Go, or Docker)

  • Claude Desktop with MCP support

Verify the HTTP endpoint before configuring Claude:

curl -s http://localhost:3000/_mcp | head

You should see JSON with "name": "prest" and a tools array. If auth is enabled, include your usual Authorization header.

Prefer a read-only PostgreSQL role for AI access.


Install the adapter

brew install prest/tap/prest-mcp

Other options: Install pREST MCP Adapter. Confirm the binary is on your PATH (Claude Desktop often needs an absolute path — see below):


Configure Claude Desktop

Edit Claude’s MCP config file:

Platform
Path

macOS

~/Library/Application Support/Claude/claude_desktop_config.json

Windows

%APPDATA%\Claude\claude_desktop_config.json

Basic config

With authentication

When auth is enabled on pREST:

Do not commit this file to a shared repo if it contains tokens.

Absolute path

GUI apps on macOS often have a minimal PATH. Prefer an absolute command:

On Intel Mac Homebrew installs, use /usr/local/bin/prest-mcp.


Verify in Claude Desktop

  1. Fully quit and reopen Claude Desktop (MCP config is loaded at startup).

  2. Open a new chat and look for the MCP / tools indicator for the prest server.

  3. Ask Claude to use pREST, for example:

    • “Using the prest MCP server, list available databases.”

    • “Describe table public.users.”

    • “Fetch up to 5 rows from public.orders.”

Claude should invoke tools such as prest.list_databases, prest.describe_table, or schema-aware prest.select.* tools. See MCP over HTTP for arguments, auth, and the 100-row select limit.


Optional: Docker-backed adapter

Ensure Docker Desktop is running before starting Claude.


Troubleshooting

Symptom
Fix

prest never appears

Quit Claude completely and reopen; check JSON syntax in the config file

Server error / spawn failed

Use an absolute path to prest-mcp; GUI apps may not see Homebrew’s PATH

Auth failures

Set PREST_MCP_TOKEN

Connection refused

Start pREST; confirm PREST_MCP_URL

Empty tools

Check permissions and curl discovery on /_mcp

Logs from the adapter go to stderr; Claude Desktop surfaces MCP server errors in its developer / MCP UI depending on version.

More detail: Install pREST MCP Adapter and MCP over HTTP.


Next steps

Last updated