Skip to content

Instantly share code, notes, and snippets.

@TheLinuxGuy
TheLinuxGuy / thelinuxguy-teslafi-data-exporter.py
Last active April 5, 2025 22:10
Export your TeslaFi user data to CSV format that TeslaMate can easily import (fixes bugs in the official script)
# Author: Giovanni Mazzeo (github.com/thelinuxguy)
# Script fetches your TeslaFi.com user data to allow importing into TeslaMate.
# Updated 04/05/2025 to include more fields to normalize based on comments in gist.
# My script fixes a couple bugs and issues seen by other people running the older script:
# 1) "Invalid CSV delimiter" issue: https://github.com/teslamate-org/teslamate/issues/4569
# 2) "battery_level" column integeter data change in 2024. https://github.com/teslamate-org/teslamate/issues/4477
# You can thank me by buying me a coffee :)