Published on [Permalink]
Reading time: 2 minutes

From Trakt.tv to Org-mode: Taking Control of My Watch History

I’ve been using Trakt.tv to track my movies and TV shows for years. It’s great for automatic scrobbling and keeping a history, but I wanted something more personal—a way to see my media library in plain text that I could manage alongside my other notes in Emacs.

So I built a simple Python script to convert my Trakt export into org-mode tables.

The Problem

Trakt is excellent at what it does, but:

The Solution

The converter pulls data from a Trakt JSON export and generates clean org-mode files:

| Name         | IMDB | Last Episode | Progress | Status   |
|--------------+------+--------------+----------+----------|
| Breaking Bad | IMDB | S05E16       | 62/62    | Complete |
| Black Mirror | IMDB | S06E01       | 22/32    | Watching |
| 30 Rock      | IMDB | S04E22       | 80/138   | Dropped  |
| Severance    | IMDB | S00E00       |          | Watchlist|

The status column is the key feature. By fetching episode counts from TMDB, the script can tell me:

Movies get a simpler treatment—just title, IMDB link, last watched date, and whether it’s watched or on my watchlist.

Technical Details

The stack is minimal:

The whole thing runs with uv run convert.py and generates three files: movies.org, shows.org, and collection.org.

One nice touch: personal Trakt lists automatically exclude items that appear in the main files, so there’s no duplication.

What’s Next

For now, this is a one-way export. The org files are my read-only reference. But org-mode tables are easy to edit, so I could potentially:

The code is straightforward—about 400 lines of Python. Sometimes the best tool is the one you build yourself.


The project is available on my https://forgejo.mayer.rocks/public/trakt-to-org Feel free to adapt it for your own Trakt exports.

Mastodon