Automate Plex Collections and Playlists with Kometa and Trakt

Published 2026-10-16 · PlexBeam

Manually creating and maintaining collections and playlists breaks down once your library passes a few hundred items. Automation tools handle the work — building collections from external databases, maintaining playlists from watch history, applying overlays, and keeping everything current as your library grows. This guide covers the two most powerful automation tools for Plex organization.

Kometa: The Collection Automation Engine

Kometa (formerly Plex Meta Manager) is the standard tool for automated Plex library organization. It creates collections, applies poster overlays, manages metadata, and maintains everything on a schedule.

What Kometa Automates

  • Collection creation: Build collections from TMDb lists, IMDb charts, Trakt lists, MDBList aggregations, and custom criteria.
  • Collection maintenance: Items are added and removed automatically as your library changes and external lists update.
  • Poster overlays: Resolution badges, audio format indicators, HDR type, ratings, and custom ribbons applied directly to posters.
  • Metadata management: Genres, labels, and other metadata fields updated from authoritative sources.
  • Artwork: Collection posters pulled automatically from The Poster Database or other configured sources.

Installation

Kometa runs as a standalone application alongside your Plex server:

  • Docker (recommended): The Docker image includes all dependencies and runs isolated from your system. A single docker-compose entry gets it running.
  • Python: Install directly on your system if Docker is not available. Requires Python 3.8 or later.
  • Unraid: Available as a Community Applications template for one-click setup.

Core Configuration

Kometa uses YAML configuration files:

  • config.yml: The main configuration file. Defines your Plex server connection, API keys for external services (TMDb, Trakt, MDBList), and global settings.
  • Library files: Per-library YAML files defining which collections to create, which overlays to apply, and which metadata operations to run.
  • Template files: Reusable collection definitions that can be applied across multiple libraries with variable substitution.

Collection Recipes

Kometa collections pull from external data sources:

  • TMDb collections: Official franchise groupings (all Marvel Cinematic Universe films, all James Bond films). TMDb maintains these lists authoritatively.
  • IMDb charts: Top 250 movies, most popular this week, highest rated by genre. These update dynamically.
  • Trakt lists: Community-curated lists covering every imaginable theme — best time travel movies, underrated 90s comedies, award season contenders. Thousands of public lists available.
  • MDBList: Aggregated lists combining data from multiple sources. Useful for complex criteria that no single source covers.
  • Custom filters: Plex-native smart collection filters defined in YAML syntax. Same criteria as manual smart collections but managed through code.

Overlay Configuration

Overlays add informational badges to individual item posters within your library:

  • Define overlay images (resolution badges, audio format icons) or use Kometa's built-in overlay assets.
  • Specify position, size, and conditions for each overlay.
  • Overlays stack — a single poster can show resolution, audio format, and HDR type simultaneously without conflicts when positions are configured correctly.
  • Kometa backs up original posters before applying overlays, so removing overlays later restores the original artwork.

Scheduling

Run Kometa on a timer for hands-free maintenance:

  • Nightly runs: Process new content added during the day, update external list collections, refresh overlays.
  • Weekly deep runs: Full library scan for metadata corrections, collection membership validation, and overlay refresh.
  • Docker scheduling: Use the built-in schedule option in the Docker configuration or an external scheduler like cron.

Trakt: Watch History and List Synchronization

Trakt tracks your viewing habits across platforms and provides community-driven content discovery. Its Plex integration synchronizes data bidirectionally.

What Trakt Syncs

  • Watch history: Everything you watch in Plex gets logged in Trakt. Useful for maintaining a complete record across multiple Plex servers or media players.
  • Ratings: Personal ratings sync between Plex and Trakt.
  • Watchlist: Your Trakt watchlist can populate a Plex playlist automatically.
  • Collection tracking: Mark items as collected in Trakt when they exist in your Plex library.

Setting Up Trakt with Plex

  1. Create a Trakt account and register for an API application to get your client ID and secret.
  2. Install the Trakt scrobbler plugin or configure Trakt through Kometa.
  3. Authorize the connection between your Plex and Trakt accounts.
  4. Configure sync direction — Plex to Trakt, Trakt to Plex, or both.

Trakt Lists as Collection Sources

Trakt's community lists are a powerful collection source when connected through Kometa:

  • Popular lists: Thousands of curated lists maintained by active community members. Oscar Best Picture winners, AFI Top 100, films by decade, and niche themes.
  • Personal lists: Create your own Trakt lists and have them automatically become Plex collections via Kometa.
  • Dynamic lists: Trakt's trending and popular lists change over time, so collections built from them stay current.

Combining Kometa and Trakt

The most powerful setup uses both tools together:

Workflow Example

  1. Trakt tracks everything you watch across all devices.
  2. Kometa reads your Trakt watch history and creates collections based on patterns (most watched genres, favorite decades, frequently rewatched).
  3. Kometa also pulls from Trakt community lists to create discovery collections (trending this week, hidden gems, award contenders).
  4. Kometa applies overlays to all items so you can see quality information at a glance.
  5. The entire system runs nightly without any manual intervention.

Playlist Automation Through Kometa

Kometa can create and maintain playlists in addition to collections:

  • Watchlist playlist: Your Trakt watchlist synced as a Plex playlist, ordered by date added.
  • Recommended playlist: Items from Trakt's recommendation engine populated into a personal Plex playlist.
  • Rewatch candidates: Items you rated highly on Trakt but have not watched in over a year, shuffled for variety.

MDBList: Aggregated Intelligence

MDBList combines data from IMDb, TMDb, Trakt, Letterboxd, and other sources into unified lists:

  • Score aggregation: Combined ratings from multiple platforms give a more balanced quality signal than any single source.
  • Custom list builder: Create lists with complex criteria — IMDb rating above 7.0 AND Trakt popular AND released after 2020 AND genre is sci-fi.
  • Kometa integration: MDBList works as a first-class collection source in Kometa configuration.

Automation Best Practices

Start Small

Do not try to automate everything at once:

  • Begin with a few franchise collections from TMDb and one or two genre collections from Trakt.
  • Add overlays after collections are working correctly.
  • Expand to more complex configurations once you understand the YAML syntax and scheduling.

Use Templates

Kometa templates reduce configuration duplication:

  • Define a genre collection template once — poster style, sort order, display mode.
  • Apply it to every genre with just the genre name as a variable.
  • Changes to the template propagate to all collections using it.

Test Before Scheduling

Run Kometa manually and review the output before enabling automatic scheduling:

  • Check that collections contain the expected items.
  • Verify overlays appear correctly on posters.
  • Look for unexpected collection memberships caused by metadata quirks.
  • Confirm that the run completes in a reasonable time — large libraries with many collections can take hours on first run.

Backup Original Artwork

Kometa modifies poster images when applying overlays:

  • Kometa's built-in backup system preserves originals, but verify that backups exist before running overlay operations.
  • If you use custom posters, apply them before running Kometa so the backup captures your custom artwork, not the default.

Troubleshooting

Collections Not Appearing

  • Check Kometa logs for errors during the collection creation step.
  • Verify that the Plex library specified in Kometa's config matches the actual library name exactly, including capitalization.
  • Confirm that the external API (TMDb, Trakt) returned results — temporary API outages cause empty collections.

Overlays Not Applied

  • Overlay operations run after collection operations. If the Kometa run was interrupted, overlays may not have processed.
  • Check that overlay image files exist at the paths specified in your configuration.
  • Some items may not have the metadata required for overlay conditions (resolution not detected, audio format not identified).

Trakt Sync Not Working

  • Re-authorize the Trakt connection — tokens expire periodically.
  • Check that the Trakt API application is still active in your Trakt account settings.
  • Verify that the sync direction is configured correctly — a Plex-to-Trakt only configuration will not populate Plex playlists from Trakt data.
← Back to Blog
More from LuxuriousComputers: LuxuriousComputers · Computer Repair · Remote Fix · Phone Repair · HVAC · Plex Support