snowflake
MCP Server for connecting to Snowflake with read-only questions
claude mcp add --transport stdio dynamike-snowflake-mcp-server uv run snowflake-mcp-stdio \ --env SNOWFLAKE_AUTH_TYPE="authentication method (private_key or external_browser)" \ --env SNOWFLAKE_PRIVATE_KEY_PATH="path to private key (required if SNOWFLAKE_AUTH_TYPE=private_key)" \ --env SNOWFLAKE_CONN_REFRESH_HOURS="hours between connection refresh (default: 8)"
How to use
This MCP server provides read-only access to Snowflake data via MCP-compatible handlers. It supports listing databases and views, describing views, querying views, and executing read-only SQL statements (SELECT, SHOW, DESCRIBE, EXPLAIN, WITH). Authentication can be done with a service account using a private key or via an interactive external browser flow. The server runs in stdio mode for easy integration with Claude Desktop or other MCP clients. Start the server using the uv package manager and connect through the stdio transport to issue queries and retrieve results as markdown tables or structured data.
How to install
Prerequisites:
- Python 3.12 or higher
- uv package manager (recommended)
- Access to a Snowflake account (service account with private key or regular user for browser-based login)
Steps:
-
Clone the repository: git clone https://github.com/yourusername/snowflake-mcp-server.git cd snowflake-mcp-server
-
Install the package in editable mode: uv pip install -e .
-
Create a .env file with your Snowflake credentials using one of the provided examples:
- For private key authentication:
cp .env.private_key.example .env
Edit .env to set SNOWFLAKE_AUTH_TYPE=private_key and path to your private key
- For external browser authentication:
cp .env.browser.example .env
Edit .env to set SNOWFLAKE_AUTH_TYPE=external_browser
- For private key authentication:
cp .env.private_key.example .env
-
Run the server (stdio transport) via uv: uv run snowflake-mcp-stdio
This starts the stdio-based MCP server; you can connect Claude Desktop or any MCP client that supports stdio transport.
Additional notes
Environment variables control connection behavior and authentication:
- SNOWFLAKE_AUTH_TYPE controls the auth method (private_key or external_browser).
- SNOWFLAKE_PRIVATE_KEY_PATH is required when using private_key authentication.
- SNOWFLAKE_CONN_REFRESH_HOURS sets how often connection pools refresh in the background (default 8 hours).
Security reminders:
- Do not commit .env files; add them to .gitignore and manage secrets securely.
- The server enforces read-only operations and automatically limits result sizes to prevent large data transfers.
If you encounter issues with browser-based authentication, ensure your Snowflake account allows interactive logins and your environment can open a browser window from the server process.
Related MCP Servers
web-eval-agent
An MCP server that autonomously evaluates web applications.
ros
Connect AI models like Claude & GPT with robots using MCP and ROS.
django
Django MCP Server is a Django extensions to easily enable AI Agents to interact with Django Apps through the Model Context Protocol it works equally well on WSGI and ASGI
fhir
FHIR MCP Server – helping you expose any FHIR Server or API as a MCP Server.
unitree-go2
The Unitree Go2 MCP Server is a server built on the MCP that enables users to control the Unitree Go2 robot using natural language commands interpreted by a LLM.
mcp -python-template
This template provides a streamlined foundation for building Model Context Protocol (MCP) servers in Python. It's designed to make AI-assisted development of MCP tools easier and more efficient.