A custom Lovelace card for the Leasing Tracker integration.
🌐 Language / Sprache: 🇬🇧 English · 🇩🇪 Deutsch
- 1st version on my test system
- On my live system
- 🔍 Smart sensor detection - Automatically finds all sensors of a Leasing Tracker vehicle
- 🚗 Multiple vehicles - One card per vehicle
- 🎨 Color coding - Green/Yellow/Red status
- 📱 Responsive - Works everywhere
- ⚙️ Graphical editor - Configure everything with clicks, no YAML required
- 🌐 Automatic translation - Texts follow the Home Assistant system language (German / English)
This card requires the Leasing Tracker Integration!
Install the integration first, then this card.
You only provide one entity - the status sensor:
entity: sensor.my_leasing_statusThe card then automatically finds all other sensors of the same vehicle.
How? The card determines the device of the status sensor and reads all associated sensors directly from the device registry. This is language- and rename-proof - it doesn't matter whether the sensors are named in German, English or Dutch, or whether you renamed them.
Note: Older card versions (< 1.2.0) searched for the sensors by their names. With the new Leasing Tracker integration this no longer works reliably - therefore the device registry is used from v1.2.0 onwards.
Open the browser console (F12) and look for:
Leasing Tracker Card - Gefundene Sensoren: {...}
There you can see which sensors the card has found.
Example: You have 2 cars
Integration config: Name = "BMW Leasing"
→ Creates sensors with prefix: bmw_leasing_
type: custom:leasing-tracker-card
entity: sensor.bmw_leasing_status
title: BMW 3 SeriesIntegration config: Name = "Audi Leasing"
→ Creates sensors with prefix: audi_leasing_
type: custom:leasing-tracker-card
entity: sensor.audi_leasing_status
title: Audi A4type: vertical-stack
cards:
- type: custom:leasing-tracker-card
entity: sensor.bmw_leasing_status
title: BMW 3 Series
- type: custom:leasing-tracker-card
entity: sensor.audi_leasing_status
title: Audi A4type: horizontal-stack
cards:
- type: custom:leasing-tracker-card
entity: sensor.bmw_leasing_status
title: BMW 3 Series
- type: custom:leasing-tracker-card
entity: sensor.audi_leasing_status
title: Audi A4- HACS → Frontend → ⋮ → Custom repositories
- URL:
https://github.com/foxxxhater/leasing-tracker-card - Category: Dashboard
- Install
- Clear browser cache (Ctrl + F5)
- Download
leasing-tracker-card.js - Copy the file to
/config/www/leasing-tracker-card/- create the path if necessary - Register the resource:
- Settings → Dashboards → ⋮ → Resources
- URL:
/local/leasing-tracker-card/leasing-tracker-card.js - Type: JavaScript Module
- Restart Home Assistant
- Clear browser cache (Ctrl + Shift + R)
Minimal:
type: custom:leasing-tracker-card
entity: sensor.my_leasing_statusWith title:
type: custom:leasing-tracker-card
entity: sensor.my_leasing_status
title: My BMW 3 SeriesOnly important sensors:
type: custom:leasing-tracker-card
entity: sensor.my_leasing_status
title: My Car
show_km_remaining_month: true
show_km_difference: true
show_progress: true
show_km_remaining_year: false
show_km_driven: false
show_average_day: false| Option | Default | Description |
|---|---|---|
entity |
required | Status sensor |
title |
Leasing Tracker |
Title |
show_title |
true |
Show/hide title |
show_status |
true |
Show/hide status badge |
show_km_remaining_month |
true |
Remaining (month) |
show_km_remaining_year |
true |
Remaining (year) |
show_km_remaining_total |
true |
Remaining (total) |
show_km_driven |
true |
Distance driven |
show_km_difference |
true |
Difference to plan |
show_average_day |
true |
Ø per day |
show_average_month |
true |
Ø per month |
show_remaining_days |
true |
Remaining days |
show_end_date |
true |
Lease end date |
show_estimated_lease_end |
true |
Estimated odometer at lease end |
show_excess_km |
true |
Estimated excess distance |
show_excess_cost |
true |
Estimated excess cost |
show_progress |
true |
Progress bar |
columns |
2 |
Number of columns (desktop) |
columns_mobile |
1 |
Number of columns (mobile, < 600px) |
date_format |
(HA setting) | Override date format: DMY, MDY or YMD. If omitted, the Home Assistant locale setting is used |
metric_background |
- | Background color of the individual tiles |
metric_background_hover |
- | Background color on mouse hover |
Tip: From v1.2.0 onwards all options can also be set conveniently in the graphical editor - including selecting the status sensor via dropdown.
- 🟢 On Plan - Green
- 🟡 Over Plan - Yellow
- 🔴 Significantly Over Plan - Red
- 🟢 > 500 km - Green
- 🟡 0-500 km - Yellow
- 🔴 < 0 km - Red
- 🟢 < 0 - Under plan
- 🟡 0-1000 - Slightly over plan
- 🔴 > 1000 - Significantly over plan
type: grid
columns: 3
cards:
- type: custom:leasing-tracker-card
entity: sensor.car_1_leasing_status
title: Car 1
- type: custom:leasing-tracker-card
entity: sensor.car_2_leasing_status
title: Car 2
- type: custom:leasing-tracker-card
entity: sensor.car_3_leasing_status
title: Car 3type: custom:leasing-tracker-card
entity: sensor.my_leasing_status
show_km_remaining_month: true
show_km_difference: true
show_progress: true
# Hide everything else
show_km_remaining_year: false
show_km_remaining_total: false
show_km_driven: false
show_average_day: false
show_average_month: false
show_remaining_days: false- Home Assistant: 2023.x+
- Leasing Tracker Integration: v1.1.3+ (new sensors require v1.4.0+)
- Core: 2026.1.2 and 2026.1.3
- Supervisor: 2026.01.1
- OS: 16.x and 17.0
- Frontend: 20260107.2
GitHub Repository Documentation Issues
MIT License
-
- Version auf meinem Test System
- Auf meinem Live System
- 🔍 Intelligente Sensor-Suche - Findet automatisch alle Sensoren eines Leasing-Tracker-Fahrzeugs
- 🚗 Mehrere Fahrzeuge - Eine Card pro Fahrzeug
- 🎨 Farbcodierung - Grün/Gelb/Rot Status
- 📱 Responsive - Funktioniert überall
- ⚙️ Grafischer Editor - Alles per Klick konfigurierbar, kein YAML nötig
- 🌐 Automatische Übersetzung - Texte richten sich nach der Systemsprache von Home Assistant (Deutsch / Englisch)
Diese Card benötigt die Leasing Tracker Integration!
Installiere zuerst die Integration, dann diese Card.
Es wird nur eine Entity angegeben - der Status-Sensor:
entity: sensor.mein_leasing_statusDie Card findet dann automatisch alle anderen Sensoren des gleichen Fahrzeugs.
Wie? Die Card ermittelt das Gerät (Device) des Status-Sensors und liest alle dazugehörigen Sensoren direkt aus der Geräte-Registry aus. Das ist sprach- und umbenennungssicher - egal ob die Sensoren auf Deutsch, Englisch oder Niederländisch benannt sind oder ob du sie umbenannt hast.
Hinweis: Ältere Karten-Versionen (< 1.2.0) haben die Sensoren über deren Namen gesucht. Mit der neuen Leasing-Tracker-Integration funktioniert das nicht mehr zuverlässig - daher wird ab v1.2.0 die Geräte-Registry verwendet.
Öffnen Sie die Browser-Console (F12) und suchen Sie nach:
Leasing Tracker Card - Gefundene Sensoren: {...}
Dort sehen Sie welche Sensoren die Card gefunden hat.
Beispiel: Sie haben 2 Autos
Integration-Config: Name = "BMW Leasing"
→ Erstellt Sensoren mit Präfix: bmw_leasing_
type: custom:leasing-tracker-card
entity: sensor.bmw_leasing_status
title: BMW 3erIntegration-Config: Name = "Audi Leasing"
→ Erstellt Sensoren mit Präfix: audi_leasing_
type: custom:leasing-tracker-card
entity: sensor.audi_leasing_status
title: Audi A4type: vertical-stack
cards:
- type: custom:leasing-tracker-card
entity: sensor.bmw_leasing_status
title: BMW 3er
- type: custom:leasing-tracker-card
entity: sensor.audi_leasing_status
title: Audi A4type: horizontal-stack
cards:
- type: custom:leasing-tracker-card
entity: sensor.bmw_leasing_status
title: BMW 3er
- type: custom:leasing-tracker-card
entity: sensor.audi_leasing_status
title: Audi A4- HACS → Frontend → ⋮ → Benutzerdefinierte Repositories
- URL:
https://github.com/foxxxhater/leasing-tracker-card - Kategorie: Dashboard
- Installieren
- Browser-Cache leeren (Strg + F5)
- Laden Sie die
leasing-tracker-card.jsherunter - Kopieren Sie die Datei nach
/config/www/leasing-tracker-card/- Den Pfad gegebenenfalls anlegen - Ressource registrieren:
- Einstellungen → Dashboards → ⋮ → Ressourcen
- URL:
/local/leasing-tracker-card/leasing-tracker-card.js - Typ: JavaScript-Modul
- Home Assistant neu starten
- Browser-Cache leeren (Strg + Shift + R)
Minimal:
type: custom:leasing-tracker-card
entity: sensor.mein_leasing_statusMit Titel:
type: custom:leasing-tracker-card
entity: sensor.mein_leasing_status
title: Mein BMW 3erNur wichtige Sensoren:
type: custom:leasing-tracker-card
entity: sensor.mein_leasing_status
title: Mein Auto
show_km_remaining_month: true
show_km_difference: true
show_progress: true
show_km_remaining_year: false
show_km_driven: false
show_average_day: false| Option | Default | Beschreibung |
|---|---|---|
entity |
erforderlich | Status-Sensor |
title |
Leasing Tracker |
Titel |
show_title |
true |
Titel anzeigen/ausblenden |
show_status |
true |
Status-Badge anzeigen/ausblenden |
show_km_remaining_month |
true |
Verbleibend (Monat) |
show_km_remaining_year |
true |
Verbleibend (Jahr) |
show_km_remaining_total |
true |
Verbleibend (Gesamt) |
show_km_driven |
true |
Gefahrene Strecke |
show_km_difference |
true |
Differenz zum Plan |
show_average_day |
true |
Ø pro Tag |
show_average_month |
true |
Ø pro Monat |
show_remaining_days |
true |
Verbleibende Tage |
show_end_date |
true |
Leasing-Enddatum |
show_estimated_lease_end |
true |
Geschätzter Stand am Leasingende |
show_excess_km |
true |
Geschätzte Mehr-Strecke |
show_excess_cost |
true |
Geschätzte Mehrkosten |
show_progress |
true |
Fortschrittsbalken |
columns |
2 |
Anzahl der Spalten (Desktop) |
columns_mobile |
1 |
Anzahl der Spalten (Mobil, < 600px) |
date_format |
(HA-Einstellung) | Datumsformat überschreiben: DMY, MDY oder YMD. Ohne Angabe wird die Home-Assistant-Einstellung verwendet |
metric_background |
- | Hintergrundfarbe der einzelnen Elemente |
metric_background_hover |
- | Hintergrundfarbe beim Drüberfahren mit der Maus |
Tipp: Ab v1.2.0 lassen sich alle Optionen auch bequem im grafischen Editor einstellen - inklusive Auswahl des Status-Sensors per Dropdown.
- 🟢 Im Plan - Grün
- 🟡 Über Plan - Gelb
- 🔴 Deutlich über Plan - Rot
- 🟢 > 500 km - Grün
- 🟡 0-500 km - Gelb
- 🔴 < 0 km - Rot
- 🟢 < 0 - Unter Plan
- 🟡 0-1000 - Leicht über Plan
- 🔴 > 1000 - Deutlich über Plan
type: grid
columns: 3
cards:
- type: custom:leasing-tracker-card
entity: sensor.wagen_1_leasing_status
title: Wagen 1
- type: custom:leasing-tracker-card
entity: sensor.wagen_2_leasing_status
title: Wagen 2
- type: custom:leasing-tracker-card
entity: sensor.wagen_3_leasing_status
title: Wagen 3type: custom:leasing-tracker-card
entity: sensor.mein_leasing_status
show_km_remaining_month: true
show_km_difference: true
show_progress: true
# Alles andere ausblenden
show_km_remaining_year: false
show_km_remaining_total: false
show_km_driven: false
show_average_day: false
show_average_month: false
show_remaining_days: false- Home Assistant: 2023.x+
- Leasing Tracker Integration: v1.1.3+ (neue Sensoren benötigen v1.4.0+)
- Core: 2026.1.2 und 2026.1.3
- Supervisor: 2026.01.1
- OS: 16.x und 17.0
- Frontend: 20260107.2
GitHub Repository Dokumentation Issues
MIT License
Happy Leasing Tracking! 🚗💨
P.S. Mit freundlicher Unterstützung von Claude