TeslaMate

v1.0.0Monitoring & Observabilitystable

🐍 🏠 - A Model Context Protocol (MCP) server that provides access to your TeslaMate database, allowing AI assistants to query Tesla vehicle data and analytics.

mcpmcp-serverteslatesla-apiteslamate
Share:
127
Stars
0
Downloads
0
Weekly
0/5

What is TeslaMate?

TeslaMate is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to 🐍 🏠 - a model context protocol (mcp) server that provides access to your teslamate database, allowing ai assistants to query tesla vehicle data and analytics.

🐍 🏠 - A Model Context Protocol (MCP) server that provides access to your TeslaMate database, allowing AI assistants to query Tesla vehicle data and analytics.

This server falls under the Monitoring & Observability category on MCPgee, the world's largest MCP server directory with 33,000+ servers.

Features

  • 🐍 🏠 - A Model Context Protocol (MCP) server that provides ac

Use Cases

Query TeslaMate database for Tesla vehicle analytics.
Access vehicle data and driving insights through AI assistants.
cobanov

Maintainer

LicenseMIT License
Languagepython
Versionv1.0.0
UpdatedMay 21, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

Manual Installation

npx teslamate

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

How to Set Up and Use TeslaMate

TeslaMate MCP Server connects your TeslaMate PostgreSQL database to AI assistants, exposing 20 specialized tools that surface Tesla vehicle analytics without writing SQL by hand. It covers battery health and degradation trends, charging session summaries, driving efficiency metrics, visited locations, and tire pressure patterns. A hardened `run_sql` tool lets you execute arbitrary read-only queries against your own TeslaMate schema, making it practical for both casual owners and data-driven enthusiasts who want natural-language access to their fleet data.

Prerequisites

  • TeslaMate already running and logging data to a PostgreSQL database
  • Python 3.11+ (for local setup) or Docker with Docker Compose (for containerized deployment)
  • PostgreSQL connection string (DATABASE_URL) for the TeslaMate database
  • An MCP-compatible client such as Claude Desktop or Claude Code
  • uv package manager installed (for local Python setup)
1

Clone the repository

Clone the teslamate-mcp repository and enter the project directory.

git clone https://github.com/cobanov/teslamate-mcp.git
cd teslamate-mcp
2

Configure environment variables

Copy the example environment file and edit it to point to your TeslaMate PostgreSQL database. The DATABASE_URL is required; all other variables have sensible defaults.

cp env.example .env
# Edit .env and set:
# DATABASE_URL=postgresql://user:password@host:5432/teslamate
# AUTH_TOKEN=          (optional bearer token for HTTP mode)
# PORT=8888            (HTTP bind port, default 8888)
# QUERY_TIMEOUT_MS=5000
3

Install dependencies and run locally

Use uv to sync the Python environment and start the server in stdio mode for local MCP client use.

uv sync
teslamate-mcp stdio
4

Or deploy via Docker

For a persistent remote deployment, start the server with Docker Compose. The prebuilt image is available from the GitHub Container Registry.

docker compose up -d
# Or use the prebuilt image directly:
# docker run -e DATABASE_URL=... ghcr.io/cobanov/teslamate-mcp:latest
5

Configure your MCP client

Add the server entry to your Claude Desktop or Claude Code configuration file so the client can launch and connect to it.

6

Verify available tools

List all 20 exposed tools to confirm the server is connected and can reach the TeslaMate database.

teslamate-mcp list-tools

TeslaMate Examples

Client configuration

Add this block to ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) to connect Claude Desktop to your local TeslaMate MCP server.

{
  "mcpServers": {
    "teslamate": {
      "command": "teslamate-mcp",
      "args": ["stdio"],
      "env": {
        "DATABASE_URL": "postgresql://user:password@localhost:5432/teslamate"
      }
    }
  }
}

Prompts to try

Natural-language queries you can send once the server is connected.

- "Show me my battery degradation over the past 6 months"
- "What were my top 5 longest drives this year?"
- "Summarize my charging sessions at home vs public chargers"
- "What is my average driving efficiency in Wh/km by month?"
- "List the locations I visit most frequently"

Troubleshooting TeslaMate

Server fails to start with 'could not connect to server' error

Verify DATABASE_URL is correct and that the PostgreSQL server is reachable. If TeslaMate runs in Docker, use the container's service name (e.g., postgresql://teslamate:password@db:5432/teslamate) and ensure the MCP server is on the same Docker network.

run_sql returns a timeout error for complex queries

Increase QUERY_TIMEOUT_MS in your .env file (default is 5000 ms). For large datasets also consider lowering CUSTOM_SQL_ROW_LIMIT to reduce the result set size.

Claude cannot find the teslamate-mcp command

Ensure uv sync completed without errors and that the virtualenv's bin directory is in PATH, or specify the full path to the teslamate-mcp binary in the MCP client config's "command" field.

Frequently Asked Questions about TeslaMate

What is TeslaMate?

TeslaMate is a Model Context Protocol (MCP) server that 🐍 🏠 - a model context protocol (mcp) server that provides access to your teslamate database, allowing ai assistants to query tesla vehicle data and analytics. It connects AI assistants to external tools and data sources through a standardized interface.

How do I install TeslaMate?

Follow the installation instructions on the TeslaMate GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.

Which AI clients work with TeslaMate?

TeslaMate works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.

Is TeslaMate free to use?

Yes, TeslaMate is open source and available under the MIT License license. You can use it freely in both personal and commercial projects.

Browse More Monitoring & Observability MCP Servers

Explore all monitoring & observability servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.

Quick Config Preview

{ "mcpServers": { "teslamate": { "command": "npx", "args": ["-y", "teslamate"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

Ready to use TeslaMate?

Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.

33,000+ ServersFree & Open SourceStep-by-Step Guides