Sponsored byOutsenseAI that finds your next clients
SponsorGROUOutbound, LinkedIn content and leads for B2B teamsSponsorOutsenseAI that finds your next clientsAd+Your tool hereSeen by people installing AI tools@Weekly picksThe best new tools, one email a week

pg-aiguide

MCP server by timescale Community

pg-aiguide gives AI coding assistants versioned PostgreSQL manual search and curated Postgres best-practice skills. It is for developers who want agents to write better schemas and queries. It is available as an MCP server, Agent Skills, or a Claude Code plugin.

  • Score 90
  • 1.9k stars
  • Apache-2.0
  • Updated

Install pg-aiguide

Built from the published package, never by AI.

claude mcp add pg-aiguide -e OPENAI_API_KEY=YOUR_OPENAI_API_KEY -e PGHOST=YOUR_PGHOST -e PGPORT=YOUR_PGPORT -e PGUSER=YOUR_PGUSER -e PGPASSWORD=YOUR_PGPASSWORD -e PGDATABASE=YOUR_PGDATABASE -- npx -y @tigerdata/pg-aiguide

Run in your terminal. Add --scope user to use it in every project.

Step-by-step: install pg-aiguide in Claude Code

MCP servers run with your permissions and can read what you give them access to. Some need an API key: check the README and add it under env in the pg-aiguide block.

About

pg-aiguide is a PostgreSQL knowledge source for AI coding assistants. It offers semantic search across the official PostgreSQL manual, which is version-aware, along with documentation for TimescaleDB and PostGIS. It also provides curated, opinionated Postgres best-practice skills that agents use automatically, covering schema design, indexing, data types, constraints, naming and performance tuning.

It can be used in three ways: as Agent Skills installed with npx skills, as a public MCP server hosted at mcp.tigerdata.com, or as a Claude Code plugin. The project says it helps AI tools avoid outdated or under-constrained Postgres code. It is aimed at developers and teams who use AI coding agents to write PostgreSQL schemas and queries. Timescale publishes it under the Apache 2.0 license.

Written from the project's README and checked against it.

Tools it gives your assistant

  • search_docsSearches PostgreSQL, TimescaleDB and PostGIS docs using semantic or keyword search.
  • view_skillExposes curated PostgreSQL best-practice skills that assistants use automatically.

What you need

  • An AI coding agent such as Claude Code, Cursor, Codex, Gemini CLI or VS Code
  • npx, for installing Agent Skills
SettingNeededWhat it is
OPENAI_API_KEYEnvironment variable, secretRequiredYour API key for text embeddings via OpenAI
PGHOSTEnvironment variable, secretRequiredPostgreSQL host to connect to
PGPORTEnvironment variable, secretRequiredPostgreSQL port to connect to
PGUSEREnvironment variable, secretRequiredPostgreSQL user to connect as
PGPASSWORDEnvironment variable, secretRequiredPostgreSQL password to connect with
PGDATABASEEnvironment variable, secretRequiredPostgreSQL database to connect to
DB_SCHEMAEnvironment variable, secretOptionalPostgreSQL database schema to use

From the publisher's entry in the official MCP Registry. Required settings are already in the install config below as placeholders.

Try asking

  • Create a Postgres table schema for storing usernames and unique email addresses.
  • Use pg-aiguide to search the PostgreSQL manual for partial index syntax.
  • Use pg-aiguide to review my schema for missing constraints and indexes.

Good to know

  • Ecosystem docs cover TimescaleDB and PostGIS today; pgvector is listed as coming soon.
  • PostGIS is listed with docs only, not skills.

Security check

A

No download-and-run commands, hidden instructions or signs of sending keys out were found.

Checked automatically: README.md, package.json. This looks for known risky patterns and is not a full audit. How grades work

Alternatives to pg-aiguide

All alternatives →
Supabase supabase
97

Connects Supabase projects to AI assistants such as Cursor, Claude and Windsurf over the Model Context Protocol. It lets assistants manage tables, fetch config and query data in a Supabase project.

AAA Local and remote 150k/wk
ArcadeDB MCP Server ArcadeData
94

ArcadeDB MCP Server is the built-in Model Context Protocol server of the ArcadeDB multi-model database. It lets AI assistants and LLMs work with ArcadeDB's graph, document, time-series, vector and other data models. It suits people who already run ArcadeDB and want assistant access to it.

AAA Local 1.3k
DBHubbytebase
94

Connects MCP clients such as Claude Desktop, Cursor and VS Code to PostgreSQL, MySQL, MariaDB, SQL Server, Oracle, ClickHouse and SQLite. It exposes two tools by default, with read-only mode and query timeouts available as guardrails.

AAA Local 343k/wk
MCP Toolbox for Databasesgoogleapis
94

MCP Toolbox for Databases is an open source MCP server that connects AI agents, IDEs and applications to enterprise databases. It provides prebuilt tools for exploring schemas and running queries, plus a framework for custom tools. It is aimed at developers building agents that need database access.

AAA Local 17k
MCP Toolbox for Databasesgoogleapis
94

Connects AI agents, IDEs and applications to enterprise databases through the Model Context Protocol. Offers prebuilt database tools for MCP clients and a framework for building custom tools for production agents.

AAA Local 17k
mongodb-mcp-servermongodb-js
94

MongoDB MCP Server lets AI assistants interact with MongoDB databases and MongoDB Atlas. It is an official server from mongodb-js, run locally with npx or Docker. It works with self-managed deployments and Atlas clusters.

AAA Local 227k/wk

Compare with Supabase, ArcadeDB MCP Server or DBHub

pg-aiguide: common questions

Which PostgreSQL version does pg-aiguide search?

The source says search across the official PostgreSQL manual is version-aware and scoped by version, but it does not list specific versions.

Does pg-aiguide work with Claude Code?

Yes. The source describes it as a Claude Code plugin that uses its skills and the public MCP server endpoint.

Do I need an API key to use the public MCP server?

The source does not mention an API key. It gives the public MCP endpoint URL https://mcp.tigerdata.com/docs for adding to supported agents.

How do I install pg-aiguide?

In Claude Code run claude mcp add pg-aiguide -e OPENAI_API_KEY=YOUR_OPENAI_API_KEY -e PGHOST=YOUR_PGHOST -e PGPORT=YOUR_PGPORT -e PGUSER=YOUR_PGUSER -e PGPASSWORD=YOUR_PGPASSWORD -e PGDATABASE=YOUR_PGDATABASE -- npx -y @tigerdata/pg-aiguide. For Claude Desktop, Cursor and VS Code, paste the config shown above and restart. See the install guides.

Is pg-aiguide the official server?

pg-aiguide is a community project by timescale, not verified by a company domain.

Is pg-aiguide free?

The code is published under the Apache-2.0 licence. The service it connects to may have its own pricing.

Is pg-aiguide safe to use?

It scores 90 of 100. Grades: maintenance A, licence A, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.

What are alternatives to pg-aiguide?

Similar MCP servers: Supabase, ArcadeDB MCP Server, DBHub, MCP Toolbox for Databases.

Does pg-aiguide work with ChatGPT?

Yes. Add its server URL in ChatGPT as a custom connector. See MCP in ChatGPT.

pg-aiguide Install

Add to stack

Loading.