List all databases in your Nile workspace
Create a new database in your Nile workspace
Get details about a specific database
Delete a database from your Nile workspace
List available regions for database creation
Create new database credentials
List all database credentials
Execute SQL queries directly on Nile databases
Nile Database MCP Server provides a seamless interface for LLM applications to interact with the Nile database platform. It enables AI assistants to create and manage databases, handle credentials, execute SQL queries, and manage multi-tenant applications directly through natural language. With this integration, developers can leverage the power of LLMs to streamline database operations, reducing the need to switch between interfaces when working with Nile's serverless Postgres platform. The server implements the full Model Context Protocol specification, ensuring compatibility with various LLM clients.
The Nile Database MCP Server allows AI assistants to interact with Nile's serverless Postgres platform. This integration enables you to manage databases, execute SQL queries, handle credentials, and work with multi-tenant applications through natural language conversations.
You can install the Nile Database MCP Server using npm:
# Install stable version
npm install @niledatabase/nile-mcp-server
# For latest alpha/preview version
npm install @niledatabase/nile-mcp-server@alpha
Alternatively, you can use other MCP package managers:
npx @michaellatman/mcp-get@latest install @niledatabase/nile-mcp-server
For manual installation:
# Clone the repository
git clone https://github.com/niledatabase/nile-mcp-server.git
cd nile-mcp-server
# Install dependencies
npm install
# Build the project
npm run build
Before using the server, you need to set up your Nile credentials. Create a .env
file in the root directory with:
NILE_API_KEY=your_api_key_here
NILE_WORKSPACE_SLUG=your_workspace_slug
To create a Nile API key:
npm run build
npm run build
env NILE_API_KEY=your_key NILE_WORKSPACE_SLUG=your_workspace node /absolute/path/to/nile-mcp-server/dist/index.js
The server supports two operational modes:
Uses standard input/output for communication, making it compatible with Claude Desktop and Cursor integrations.
Server-Sent Events (SSE) mode enables real-time, event-driven communication over HTTP.
If you encounter issues:
For more information, visit the Nile documentation or join the Discord community.