# postgresai MCP server

> Runs PostgreSQL health checks, monitoring, and issue tracking so AI clients can diagnose and fix database problems.

- Repository: https://github.com/postgres-ai/postgresai
- Page: https://hostedmcp.org/servers/postgres-ai/postgresai
- Official: yes
- Transport: —
- Stars: 140
- License: Apache-2.0

## FAQ

### How do I install the postgresai MCP server for Claude Code or Cursor?

Run 'npx postgresai mcp install' to add the MCP server to your AI coding tool. This lets agents work with Issues and Action Items from console.postgres.ai inside your IDE.

### Do I need a postgres.ai account to use postgresai?

No. Both express checkup and full monitoring are open-source and can be used without connecting to console.postgres.ai; skip 'npx postgresai auth' and use --no-upload for checkup or omit --api-key for monitoring.

### Which PostgreSQL versions does postgresai support?

The checkup requires network access to PostgreSQL 14 through 18, and Node.js 18+ is needed.

### Can AI agents consume postgresai checkup output?

Yes. Checkup reports are JSON, so you can pipe them to an LLM or print them with --json for structured diagnostics.

### Does postgresai run safely against production databases?

Diagnostic queries are designed to avoid the observer effect using timeouts, row limits, and non-blocking approaches. You can also preview the setup SQL before it runs.
