Hana MCP
SAP HANA MCP server — Enterprise Model Context Protocol server for SAP HANA. Use with Claude Code, VS Code. npm: hana-mcp-server
What is Hana MCP?
Hana MCP is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to sap hana mcp server — enterprise model context protocol server for sap hana. use with claude code, vs code. npm: hana-mcp-server
SAP HANA MCP server — Enterprise Model Context Protocol server for SAP HANA. Use with Claude Code, VS Code. npm: hana-mcp-server
This server falls under the Databases category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- SAP HANA MCP server — Enterprise Model Context Protocol serv
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx hanaConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Hana MCP
The SAP HANA MCP Server is an enterprise-grade Model Context Protocol server that gives AI assistants direct, structured access to SAP HANA and HANA Cloud databases through 34 tools spanning connection management, schema browsing, SQL execution, structural analysis, code object inspection, and performance diagnostics. It integrates with Claude Desktop, Claude Code, VS Code, and Cursor, and supports multi-tenant HANA deployments with fine-grained write permission controls — INSERT, UPDATE, and DELETE are each disabled by default and must be explicitly opted in. This makes it safe for read-heavy analytics workflows while remaining flexible for controlled write operations.
Prerequisites
- Node.js 18 or higher installed
- A reachable SAP HANA or HANA Cloud database instance
- Database credentials (host, user, password) with appropriate schema permissions
- Claude Desktop, Claude Code, Cursor, or VS Code with MCP support
- Network access from your machine to the HANA host on the configured port (default 443 for HANA Cloud)
Gather your SAP HANA connection details
Before configuring the server, collect the hostname, port, username, password, and optionally the default schema and database name (for multi-tenant MDC deployments). HANA Cloud typically uses port 443; on-premise MDC instances often use port 3NN13 where NN is the instance number.
Add the server to your MCP client configuration
Edit your claude_desktop_config.json (or equivalent MCP client config) to add the hana-mcp-server entry. The server runs via npx and requires no separate installation step.
{
"mcpServers": {
"HANA Database": {
"command": "npx",
"args": ["-y", "hana-mcp-server"],
"env": {
"HANA_HOST": "your-hana-host.hanacloud.ondemand.com",
"HANA_PORT": "443",
"HANA_USER": "your-username",
"HANA_PASSWORD": "your-password",
"HANA_SCHEMA": "YOUR_SCHEMA"
}
}
}
}Configure multi-tenant or on-premise settings (if applicable)
For multi-tenant HANA (MDC), add HANA_DATABASE_NAME to specify the tenant. For on-premise instances with self-signed certificates, set HANA_VALIDATE_CERT to false.
{
"HANA_DATABASE_NAME": "TENANT_NAME",
"HANA_PORT": "30013",
"HANA_SSL": "true",
"HANA_VALIDATE_CERT": "false"
}Enable write operations (optional)
By default all write operations are disabled. To enable specific DML operations, add the corresponding environment variables. Only enable what your use case requires.
{
"HANA_ALLOW_INSERT": "true",
"HANA_ALLOW_UPDATE": "true",
"HANA_ALLOW_DELETE": "false"
}Restart your MCP client and verify the connection
Fully restart Claude Desktop (or reload the MCP server in your client) and ask Claude to list the available schemas or verify the HANA connection. A successful response confirms the server is authenticated and connected.
Hana MCP Examples
Client configuration
Complete claude_desktop_config.json entry for the SAP HANA MCP server connecting to a HANA Cloud instance with read-only access.
{
"mcpServers": {
"HANA Database": {
"command": "npx",
"args": ["-y", "hana-mcp-server"],
"env": {
"HANA_HOST": "your-instance.hanacloud.ondemand.com",
"HANA_PORT": "443",
"HANA_USER": "DBADMIN",
"HANA_PASSWORD": "your-secure-password",
"HANA_SCHEMA": "MY_SCHEMA",
"HANA_SSL": "true",
"HANA_ALLOW_INSERT": "false",
"HANA_ALLOW_UPDATE": "false",
"HANA_ALLOW_DELETE": "false"
}
}
}
}Prompts to try
Use these prompts to explore and query your SAP HANA database through Claude once the MCP server is connected.
- "List all tables in the MY_SCHEMA schema with their row counts"
- "Show me the columns and data types for the SALES_ORDERS table"
- "Run a SQL query to find the top 10 customers by total order value this year"
- "What indexes exist on the PRODUCT_CATALOG table?"
- "Explain the execution plan for this query: SELECT * FROM ORDERS WHERE STATUS = 'PENDING'"
- "List all stored procedures in my schema and describe what each one does"Troubleshooting Hana MCP
spawn npx ENOENT error when Claude Desktop starts
Claude Desktop may not inherit your shell's PATH. Use the absolute path to npx in your config (find it with 'which npx'), or add a PATH env var: "PATH": "/usr/local/bin:/usr/bin:/bin" in the env block.
Connection refused or timeout when connecting to HANA
Verify HANA_HOST and HANA_PORT are correct and reachable: run 'nc -zv your-hana-host 443' from your machine. For HANA Cloud, ensure your IP is allowlisted in the HANA Cloud instance's allowed connections settings.
TLS certificate validation errors on connection
For on-premise HANA instances with self-signed certificates, set HANA_VALIDATE_CERT=false. For production, import the HANA server certificate into your system trust store instead of disabling validation.
Frequently Asked Questions about Hana MCP
What is Hana MCP?
Hana MCP is a Model Context Protocol (MCP) server that sap hana mcp server — enterprise model context protocol server for sap hana. use with claude code, vs code. npm: hana-mcp-server It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Hana MCP?
Follow the installation instructions on the Hana MCP GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with Hana MCP?
Hana MCP works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Hana MCP free to use?
Yes, Hana MCP is open source and available under the MIT license. You can use it freely in both personal and commercial projects.
Hana MCP Alternatives — Similar Databases Servers
Looking for alternatives to Hana MCP? Here are other popular databases servers you can use with Claude, Cursor, and VS Code.
Excelize
★ 20.6kGo language library for reading and writing Microsoft Excel™ (XLAM / XLSM / XLSX / XLTM / XLTX) spreadsheets
MCP Toolbox for Databases
★ 15.3kOpen source MCP server specializing in easy, fast, and secure tools for Databases.
DBHub
★ 2.8kA universal database gateway MCP server that enables AI assistants to connect to and query multiple databases (PostgreSQL, MySQL, MariaDB, SQL Server, SQLite) with support for schema exploration, SQL execution, and secure connections via SSH tunnels.
Tabularis
★ 2.1kA lightweight, cross-platform database client for developers. Supports MySQL, PostgreSQL and SQLite. Hackable with plugins. Built for speed, security, and aesthetics.
Postgres AI Guide
★ 1.7kMCP server and Claude plugin for Postgres skills and documentation. Helps AI coding tools generate better PostgreSQL code.
Anyquery
★ 1.7k🏎️ 🏠 ☁️ - Query more than 40 apps with one binary using SQL. It can also connect to your PostgreSQL, MySQL, or SQLite compatible database. Local-first and private by design.
Browse More Databases MCP Servers
Explore all databases servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up Hana MCP in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use Hana MCP?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.