unsubbed.co

TeslaMate

TeslaMate handles data logger for Tesla vehicles as a self-hosted solution.

Self-hosted Tesla analytics, honestly reviewed. No marketing spin, just what you get when you run this on your own server.

TL;DR

  • What it is: AGPL-3.0 self-hosted data logger for Tesla vehicles — stores every drive, charge, and sleep session in your own PostgreSQL database and visualizes it through 21+ Grafana dashboards [README].
  • Who it’s for: Tesla owners who want complete data ownership, Home Assistant users who want vehicle telemetry in their home automation stack, and self-hosters who don’t trust third-party apps with their location history and API keys [README][3].
  • Cost savings: Cloud-based Tesla data apps like TeslaFi charge roughly $5–6/month (~$60/year). TeslaMate software is free; running it on a $5–10/month VPS or a spare Raspberry Pi brings your annual cost to $60–120 in infrastructure — but you own the data forever and the monthly bill never goes up.
  • Key strength: The most comprehensive open-source Tesla analytics available. 21 bundled Grafana dashboards covering battery degradation, vampire drain, efficiency, lifetime driving maps, charge cost tracking, and more [README][6].
  • Key weakness: It had a serious security incident in 2022 — over 100 exposed deployments leaked Tesla API keys, allowing remote vehicle access. The bug is fixed, but it reveals that default configuration requires deliberate hardening [1]. It also depends on Tesla’s unofficial API, which Tesla controls and can break.

What is TeslaMate

TeslaMate is a self-hosted data logger for Tesla vehicles. You run it on your own server, it connects to Tesla’s API using your credentials, and it records everything your car does — every drive, every charge session, where it parked, how long it slept, how much battery degraded — into a PostgreSQL database that lives on your machine [README].

The visualization layer is Grafana, which means the dashboards are customizable and the underlying data is fully queryable with SQL. Vehicle state is also published in real time to a local MQTT broker, which is what makes integration with Home Assistant and Node-RED clean and event-driven rather than polling-based [README].

The stack is: Elixir application doing the Tesla API polling and data processing, PostgreSQL for storage, Grafana for dashboards, and Mosquitto (or any MQTT broker) for real-time state publishing [README][2]. All four components ship as Docker images and are typically run together with a single docker-compose file.

The project sits at 7,770 GitHub stars under the teslamate-org organization. The original author transferred maintenance, and the current primary maintainer is @JakobLichterfeld [README]. The license is AGPL-3.0 — not MIT, despite some secondary sources claiming otherwise [README][6].


Why people choose it

There are two types of Tesla owners who end up here: people who ran a third-party cloud app and got uncomfortable with what they were handing over, and data nerds who want their driving history in a queryable database under their control.

Versus cloud apps (TeslaFi, TezLab, Tessie). The pitch from source [2] is blunt — TeslaMate gives you data access that would otherwise be hidden, and it lives on your hardware. The privacy comparison is where TeslaMate wins most clearly. Source [3], a detailed review of TezLab (TeslaMate’s most visible free competitor), spends several paragraphs wrestling with whether TezLab is selling user data: “Free platforms tend to rely on your data to thrive. Think Facebook.” The reviewer concludes TezLab probably isn’t selling data today, but acknowledges “only time will tell.” TeslaMate sidesteps this entirely — there is no company with access to your location history, charging patterns, or API credentials [README][3].

TezLab is free at the base tier but gates historical data access (beyond a rolling 7-day window) behind a paid subscription, plus a one-time “Founder Series” contribution with a minimum of US$150 for lifetime access [3]. TeslaMate is free regardless of how much history you want to keep — your retention limit is your disk space.

For Home Assistant users. The MQTT integration is a genuine differentiator. Real-time vehicle state (location, battery level, charging status, doors locked/unlocked, climate on/off) flows directly into Home Assistant via MQTT, which means automations like “turn on the garage heater when the car leaves work” work without polling or webhooks [README][6].

For data ownership absolutists. TeslaMate captures data you can’t get from Tesla’s own app in useful form — specifically the granular historical data: every individual drive with route map and efficiency breakdown, every charge session with cost tracking, battery health over time plotted against mileage, vampire drain by location, and a lifetime driving map [README][6]. When you stop using TeslaMate, the data stays in your PostgreSQL database. You can query it yourself or export it however you want.

The security incident context. Choosing TeslaMate over a cloud app for privacy reasons has an ironic counterpoint. In early 2022, security researcher David Colombo found over 100 TeslaMate deployments directly exposed to the internet with default or no authentication. Because the exposed dashboards included the owner’s Tesla API key, Colombo was able to demonstrate remote unlocking of doors, honking horns, and starting keyless driving mode on affected vehicles. He reported discovering exposed Teslas in the UK, Europe, Canada, China, and the US [1]. The bug was not in Tesla’s infrastructure — it was TeslaMate deployed without authentication, with ports open to the internet. TeslaMate pushed a fix; users had to manually deploy it [1]. This incident doesn’t make TeslaMate unsafe by design, but it does mean default deployment is not hardened deployment. If you’re running it, you need to think about authentication and network exposure deliberately.


Features

Based on the README and feature descriptions from medevel.com:

Core data logging:

  • High-precision drive data recording [README]
  • Designed to minimize vampire drain — the car falls asleep as soon as possible [README]
  • Automatic address lookup for visited locations [README]
  • Geo-fencing to define custom named locations (home, work, favorite charger) [README]
  • Supports multiple vehicles under a single Tesla account [README]
  • Charge cost tracking [README]
  • Import from TeslaFi and tesla-apiscraper if you’re migrating history [README]
  • Customizable theme (light, dark, system default) [README]

Built-in Grafana dashboards (21+): Battery Health, Charge Level, Charges (energy added vs used), Charge Details, Charging Stats, Database Information, Drive Stats, Drives (distance / energy consumed), Drive Details, Efficiency (consumption net/gross), Locations, Mileage, Overview, Projected Range (battery degradation), States (online/asleep history), Statistics, Timeline, Trip, Updates history, Vampire Drain, Visited (lifetime driving map) [README].

Integrations:

  • Home Assistant via MQTT [README][6]
  • Node-RED via MQTT [README]
  • Telegram notifications via MQTT [README]

Mobile companion apps (community-built, not official):

  • MateDroid — native Android app that reads from a TeslaMate instance via TeslamateApi (a separate REST API layer you deploy alongside TeslaMate). Features include real-time dashboard with 3D car image, charging history with charts, drive history with route visualization, battery health tracking, and software update history. GPL-3.0 licensed, connects only to your own server [4][5].

What’s missing:

  • No official mobile app
  • No built-in iOS client
  • No user-facing web interface beyond the basic data entry/config pages — all analytics live in Grafana, which requires learning basic Grafana navigation
  • No multi-tenant or cloud-hosted option

Pricing: SaaS vs self-hosted math

TeslaMate software is free under AGPL-3.0. The infrastructure cost depends on where you run it.

Self-hosted on a VPS:

  • Software: $0
  • Hetzner CX21 or similar (2 vCPU, 4GB RAM): ~$5–8/month
  • Your time to set it up: 1–3 hours initially

Self-hosted on a Raspberry Pi:

  • Software: $0
  • Raspberry Pi 4 (2GB): ~$35–45 one-time
  • Electricity: negligible
  • Effectively $0/month after hardware

Cloud-based Tesla analytics apps for comparison:

  • TeslaFi: approximately $5–6/month (pricing from general knowledge; not confirmed in the provided sources — verify at teslafi.com before deciding)
  • TezLab: free base tier with 7-day data rolling window; paid Pro tier for unlimited history; one-time “Founder Series” contribution minimum US$150 for lifetime access [3]

The math over 3 years: If you’re on a cloud Tesla data app at $5/month, that’s $180 over three years. A dedicated Raspberry Pi 4 costs ~$40 upfront plus ~$5/year in electricity — roughly $55 total over three years, with no vendor lock-in and no data on anyone else’s servers. VPS route is roughly $270 over three years if you’re running nothing else on that VPS — so the “self-hosted saves money” math requires you to either already have a server or use the Raspberry Pi path.

The more honest value proposition is data permanence and portability, not cost savings at small scale. You’re not saving hundreds per year. You’re ensuring that a company pivot, acquisition, or shutdown doesn’t erase five years of your vehicle’s history.


Deployment reality check

The official install path is Docker Compose. The default docker-compose.yml brings up four containers: TeslaMate itself, PostgreSQL, Grafana, and Mosquitto. The documentation at https://docs.teslamate.org covers Docker installation as the primary path [README][6].

What you actually need:

  • A Linux machine (VPS, Raspberry Pi 4, or spare PC) with at least 2GB RAM — 4GB recommended if you’re running Grafana heavily
  • Docker and docker-compose installed
  • A Tesla account with active vehicles
  • A domain name and HTTPS setup (Caddy or nginx reverse proxy) — critical given the 2022 exposure incident; running without HTTPS and auth is how those 100+ instances got compromised [1]
  • Basic command-line familiarity to edit the .env file and run docker-compose up

What can go wrong:

The 2022 security incident [1] is the main cautionary signal. The root cause was users deploying TeslaMate with Grafana’s anonymous access enabled and ports exposed to the internet. The fix requires explicitly disabling anonymous Grafana access and putting the whole stack behind authentication. The current documentation addresses this, but it’s not automatic — you have to follow the security configuration steps deliberately.

Tesla’s API is unofficial and has been evolving. Tesla began requiring OAuth tokens via their Fleet API, and TeslaMate has had to adapt. If Tesla changes or locks down their API, TeslaMate stops working until the project updates. This is a dependency you can’t control, and it’s the fundamental risk of any third-party Tesla integration.

The stack complexity is real: four Docker containers, PostgreSQL schema migrations on upgrade, Grafana dashboard updates on upgrade. Upgrading TeslaMate requires pulling new images and sometimes running migration commands. This is manageable but not zero-effort — expect to spend 20–30 minutes on a major version upgrade.

Realistic setup time for someone comfortable with Docker and Linux: 45–90 minutes including HTTPS configuration. For someone following the documentation carefully but newer to Docker: 3–5 hours including debugging.


Pros and cons

Pros

  • Complete data ownership. Your driving history, battery data, location history, and API credentials never leave your server. No vendor holds your data hostage [README][3].
  • 21+ Grafana dashboards out of the box. Battery degradation over time, vampire drain by location, efficiency per trip, lifetime driving maps — analytics you genuinely can’t get from Tesla’s own app in useful form [README][6].
  • MQTT integration is first-class. Real-time vehicle state flows into Home Assistant, Node-RED, and Telegram without configuration gymnastics [README].
  • No data expiry. Cloud apps gate historical data behind paid tiers. TeslaMate keeps everything, limited only by your disk [3].
  • Multi-vehicle support. One instance handles multiple cars under a Tesla account [README].
  • TeslaFi import. If you’re migrating from TeslaFi, your history comes with you [README].
  • Community-built Android client (MateDroid) — native app with real-time dashboard, charging history, drive history, and battery health. No data to third parties [4][5].
  • 7,770 GitHub stars — active project with ongoing maintenance [merged profile].

Cons

  • 2022 security incident. Over 100 deployments leaked Tesla API keys due to default-open configuration, enabling remote vehicle access by a researcher [1]. Fixed now, but it means security is something you configure, not something you get by default.
  • AGPL-3.0, not MIT. If you modify TeslaMate and run it as a networked service, you must open-source your modifications. Not relevant for personal use, but relevant if you’re building a product on top of it.
  • Depends on Tesla’s unofficial API. Tesla controls this and can break TeslaMate at any time. This is the existential risk for the project.
  • No official mobile app. MateDroid is excellent but requires deploying TeslamateApi as an additional component, and it’s Android-only [4][5].
  • Grafana learning curve. Non-technical users will find Grafana unfamiliar. The dashboards are beautiful once set up, but navigating them, creating custom panels, or understanding the data model requires some exploration.
  • Stack complexity on upgrades. Four Docker containers plus potential schema migrations make upgrades more involved than a single-container app.
  • No iOS companion app. If you’re on iPhone, there is no MateDroid equivalent. You’re looking at Grafana in a mobile browser.
  • Niche by definition. Only useful to Tesla owners. If you ever sell your car and switch brands, the tool becomes worthless.

Who should use this / who shouldn’t

Use TeslaMate if:

  • You own a Tesla and want granular analytics about battery degradation, charging efficiency, or vampire drain that Tesla’s own app doesn’t surface.
  • You’re already running Home Assistant and want your Tesla integrated into your home automation without a cloud dependency.
  • You’re paying for TeslaFi or similar and the bill bothers you — especially if you’re already running a home server or Raspberry Pi.
  • Privacy over your location history and driving patterns matters to you.
  • You’re comfortable with Docker and are willing to spend an afternoon on initial setup plus occasional maintenance.

Skip it (use TeslaFi or TezLab instead) if:

  • You want a polished mobile experience without managing infrastructure. Cloud apps handle updates, uptime, and iOS/Android clients for you.
  • You’re not comfortable with the command line or Docker. The documentation is good, but TeslaMate punishes users who skip the security configuration steps [1].
  • You’re not interested in the analytics — if you just want basic trip logging and range estimates, Tesla’s official app covers you.
  • You don’t have anywhere to run it. Without a Raspberry Pi, home server, or VPS you’re already paying for, the cost advantage shrinks or disappears.

Skip it (serious consideration) if:

  • You haven’t read the security configuration documentation before deploying. The 2022 incident showed what happens when users skip that step [1].
  • You want guarantees of long-term API compatibility. Tesla controls the API, and this project cannot guarantee it works after any given Tesla software update.

Alternatives worth considering

  • TeslaFi — the most mature cloud-based Tesla data logger. Paid subscription (~$5-6/month), polished UI, solid iOS and Android apps, reliable since 2015. The benchmark TeslaMate is measured against. Choose if you want zero infrastructure maintenance.
  • TezLab — free tier with 7-day data window, paid Pro for full history, iOS and Android apps, one-time Founder contribution available [3]. Raises legitimate data privacy questions that the review in source [3] doesn’t fully resolve.
  • Tessie — newer cloud-based option with a free tier and paid subscription. More polished UI than TeslaMate’s Grafana approach for non-technical users.
  • Tesla’s official app — covers the basics (location, charge level, climate control, remote commands). No historical analytics, no battery degradation tracking, no efficiency charts. Free and always up to date.
  • Home Assistant Tesla integration (without TeslaMate) — if you’re primarily a Home Assistant user and only want real-time state for automations, the native HA Tesla integration may be sufficient without the full TeslaMate stack.

For a Tesla owner deciding between TeslaMate and a cloud app: choose TeslaMate if data ownership and Home Assistant integration are your priority; choose TeslaFi if uptime, mobile UX, and zero maintenance are your priority.


Bottom line

TeslaMate is the right tool for a specific person: a Tesla owner who cares about what their vehicle data reveals, wants it stored locally, and is willing to spend an afternoon with Docker to make that happen. The 21 bundled Grafana dashboards are genuinely excellent — battery degradation plotted against mileage, vampire drain by location, efficiency per trip — this is the kind of analysis Tesla’s official app has never offered. The Home Assistant MQTT integration is first-class. And for anyone paying monthly for TeslaFi or a similar app, the math eventually favors a one-time Raspberry Pi purchase.

The honest caveat is that the 2022 security incident should be read as a warning about who this tool is built for. It’s not hostile to non-technical users, but it requires deliberate security configuration — and the 100+ vehicle owners whose API keys were exposed didn’t know that. If you deploy it, read the security documentation before the getting-started guide. The other caveat is Tesla itself: this tool runs on an unofficial API that Tesla controls, and the project has had to scramble through API transitions before. You’re betting on the project keeping pace with Tesla’s changes, which is a reasonable bet given 7,770 stars and active maintenance — but not a guarantee.

If the Docker deployment is the blocker, that’s exactly what upready.dev handles for clients — one-time setup, you own the infrastructure and the data.


Sources

  1. David Colombo / theinformativeblog.com“Teslamate — Security Vulnerability: TeslaMate dashboards exposed Tesla API keys”. https://www.theinformativeblog.com/teslamate/
  2. David Balan“TeslaMate — self-hosted Tesla data logger overview”. https://www.balandavid.com/en/blog/
  3. TeslaTuneUp“TezLab Review: The ‘Best’ 3rd-Party Tesla App or Not Even Close?”. https://teslatuneup.com/tezlab-review/
  4. AndroidFreeware (EN)“MateDroid APK for Android — Tesla vehicle data from your self-hosted TeslaMate instance”. https://www.androidfreeware.net/it/download-matedroid-apk.html
  5. AndroidFreeware (FR)“MateDroid APK Télécharge pour Android”. https://www.androidfreeware.net/fr/download-matedroid-apk.html
  6. Medevel“Teslamate is a Self-hosted Data logger for Tesla”. https://medevel.com/teslamate/

Primary sources:

Features

Integrations & APIs

  • Telegram Integration

Customization & Branding

  • Themes / Skins

Mobile & Desktop

  • Mobile App