Supports configuration via .env files for database credentials and connection settings
Includes CI/CD integration through GitHub Actions workflows
Provides testability with Jest for ensuring server reliability and performance
Provides a read-only query interface to PostgreSQL databases, supporting secure connections via SSH bastion tunnels
Compatible with Supabase + MCP integration, allowing models to query Supabase-managed PostgreSQL databases
Built with TypeScript for type safety and modern JavaScript features
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@SQL MCP Servershow me the top 10 customers by total orders"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
SQL MCP Server (TypeScript)
This project provides a TypeScript implementation of a Model Context Protocol (MCP) server that enables language models and other MCP-compatible clients to query PostgreSQL databases—via SSH bastion tunnels when required.
Built for flexibility and secure database access, it supports AWS RDS with read-only transactions and uses stdin/stdout-based communication, making it suitable for local, containerized, or AI-driven use cases.
Features
🔒 SSH bastion support for secure access to private RDS instances via SSH tunnels
🐘 PostgreSQL read-only query engine using the
pglibrary📡 STDIO-based MCP protocol transport
🧠 Compatible with memory-bank-mcp-server
⚙️ Easily configurable via
.envor environment variables🧪 Fully testable with Jest and mocks
Related MCP server: PostgreSQL Query MCP Server
Installation
Clone the repository and install dependencies: