trainings-sync is a command-line tool that synchronizes your workouts and health data across Garmin Connect, Strava and a local folder on your computer (FIT/GPX/TCX formats). With a single command you get a complete personal archive of all your data on your own disk — and stop depending on any single platform.

Why you need it

  • Your own data archive. All workouts and health metrics live locally in open formats — nobody can take them away or hide them behind a paywall.
  • Freedom between services. Move activities between Garmin and Strava, keep them in both, and additionally on disk.
  • Fuel for an AI coach. Local workout and health files are the ideal input for a personal AI coach that analyses your data (see the separate AI-coach article).
  • Reliability. An interrupted sync resumes from where it stopped; nothing is re-downloaded unnecessarily.

What it does (in short)

  • Syncs workouts between Garmin, Strava and a local folder (FIT/GPX/TCX).
  • Syncs health data (sleep, heart rate, HRV, stress, weight and much more).
  • Parallel processing — fast even on large archives.
  • Stores secrets in a file or a KeePass database.
  • Smart cache and resume, careful handling of API rate limits.
  • Photo and video sync for activities — a feature you rarely see in similar tools.
  • Extensibility: you can add your own connectors and secret stores.

Connectors and extensibility

Out of the box it supports three sources/destinations: Garmin Connect, Strava and a local folder. But the key point is that the system is modular: connectors implement a single interface (ServiceConnector), so you can write your own connector to any service (another platform, a corporate tracker, cloud file storage) and it plugs into the same sync pipeline. Support is not limited to Strava, Garmin and a local folder — those are just the ready-made implementations.

A single run can describe several sync groups with different directions, for example:

  1. Strava → Garmin Connect (upload Strava activities to Garmin);
  2. Garmin + Strava → local folder (save to disk, Garmin takes priority).

Health (wellness) data sync

Besides workouts the tool exports a large set of health metrics — by default on every run (disable with --skip-wellness). From Garmin Connect this includes, among others:

CategoryMetrics
Sleep & recoverysleep, HRV, Body Battery, training readiness
Heart & bloodheart rate, resting HR, SpO2, blood pressure
Stressdaily and weekly stress
Body compositionweight, body composition, weigh-ins
Activitysteps, floors, intensity minutes, hydration
PerformanceVO2max, lactate threshold, training status, endurance score, race predictions, fitness age
Miscpersonal records, summaries and stats

From Strava it exports athlete_stats and athlete_zones snapshots. Data is stored as dated JSON under the wellness/ folder. Some types (weight, body composition, blood pressure, hydration) also support writing — the connectors implement the full read/write interface.

Photo and video sync for activities

The tool moves not just the workouts but also the photos and videos attached to them: it downloads media together with the activity and, where the destination supports it, uploads them back (Garmin Connect, for example, supports photo upload). You rarely find this in similar syncers — most of them transfer only the tracks themselves.

Speed: parallel processing

The sync is built on an async core: sources are downloaded in parallel, and health metrics are fetched by a pool of workers (up to 10 concurrent tasks), so even a multi-year archive with many data types is processed quickly. At the same time the tool watches API rate limits (especially Strava's): it prints current usage to the log and automatically pauses the sync until the limit window resets, then continues.

Storing secrets

Logins and passwords can be stored in two ways:

  • A JSON file with credentials (--creds-json).
  • A KeePass database (.kdbx, --creds-keepass) — the master password is read from the KEEPASS_PASSWORD environment variable or prompted in the console.

The secret stores are extensible too: they sit behind a single abstract interface, so you can add a new store type (e.g. a system keychain or a corporate secrets manager) without touching the rest of the code.

Reliability: cache and resume

Downloaded activities and metrics are cached (cache_dir in the config). A repeat run fetches only what is missing — this speeds things up and lets you safely interrupt and resume a sync. The --force flag forces a full re-download.

Installation (quick)

You need Git, Python 3.14 and Poetry.

# 1) Install Python 3.14 and Poetry
# macOS:
brew install git python@3.14 pipx && pipx ensurepath && pipx install poetry
# Linux (Ubuntu/Debian):
sudo add-apt-repository ppa:deadsnakes/ppa && sudo apt update && sudo apt install python3.14 python3.14-venv
pip3 install pipx && pipx ensurepath && pipx install poetry
# Windows (PowerShell): install Git and Python 3.14, then: pip install pipx; pipx ensurepath; pipx install poetry

# 2) Clone and install dependencies
git clone https://github.com/dchernykh1984/trainings_sync.git
cd trainings_sync
poetry config virtualenvs.in-project true
poetry install --no-root

# 3) Copy the config templates and edit them
mkdir -p config && cp config_templates/*.json config/

Run examples

# Garmin -> local folder (credentials in JSON)
poetry run trainings-sync --config config/config.garmin-to-local.json --creds-json config/creds.json

# Same, but secrets in KeePass
poetry run trainings-sync --config config/config.garmin-to-local.json --creds-keepass /path/to/keepass.kdbx

# Strava + Garmin (full setup: Strava->Garmin and Garmin+Strava->folder)
poetry run trainings-sync --config config/config.strava-and-garmin.json --creds-json config/creds.strava-source.json

Handy options: --start/--end (date range), --force (re-download everything), --skip-wellness (no health data).

Roadmap

Right now trainings-sync is a command-line tool. If there's interest from users, a graphical interface (GUI) is planned in addition to the CLI — intended to be built with the same toolkit, PySide6 (Qt), used in the Finish Protocol Generator project.

Room to extend

  • New connectors to other services/trackers — via the single ServiceConnector interface (and its wellness variant).
  • New secret-store types — via the abstract credentials interface.
  • New file formats — the FIT/GPX/TCX parsers are uniform, so adding another is easy.

Repository

Source code, config templates and detailed docs: https://github.com/dchernykh1984/trainings_sync


*This description is based on the project's source code as of June 2026. For exact installation steps, the config format and the current list of synced data, see the repository README.*