Welcome to letterboxdpy
A modern, fast, and feature-rich Python library for scraping and interacting with Letterboxd data.
Features
- Core Letterboxd Entities: First-class models for
User,Movie,Search,List,Watchlist, andMembers. - WAF & Cloudflare Resilient: Built on
curl_cffiusing real browser TLS impersonation (chrome120) and RFC-compliant URL normalization. - Deep User Insights: Extract complete watchlists, chronological diary entries, user wrapped summaries, ratings, reviews, followers, and genre distribution.
- Advanced Film Discovery: Discover films by genre, curated themes, release years, decades, or streaming services.
- Trace-Locked Sessions: Authenticated account settings and profile updates via automated CSRF handling.
- Deterministic & Typed: Strict type hints, comprehensive offline test suite, and clean snake_case JSON schemas.
Quick Start
Installation
Basic Usage
Fetching a User
Fetching a Movie
Searching Letterboxd
Architecture Overview
flowchart TD
App[Your Application / Script] --> User[User Class]
App --> Movie[Movie Class]
App --> Search[Search Class]
App --> List[List / Watchlist]
App --> Films[Films Discovery]
App --> Auth[UserSession / Settings]
User --> Scraper[Scraper Gateway]
Movie --> Scraper
Search --> Scraper
List --> Scraper
Films --> Scraper
Auth --> Scraper
Scraper --> URLNorm[normalize_letterboxd_url]
URLNorm --> Curl[curl_cffi Chrome TLS Session]
Curl --> Letterboxd[(Letterboxd Web / CDN)]
Explore the Documentation
| Module Guide | Description | API Reference |
|---|---|---|
| Getting Started | Installation, Cloudflare resilience, core classes | - |
| User Guide | Profile stats, watched films, diary, wrapped, social | User API |
| Movie Guide | Details, cast, crew, reviews, similar movies | Movie API |
| Search Guide | Full-text search across 12 categories, slug lookup | Search API |
| List Guide | User lists, movie collections, tags, descriptions | List API |
| Watchlist Guide | Saved watchlists, genre/decade/provider filtering | Watchlist API |
| Films & Discovery | Browse upcoming, genres, themes, streaming services | Films API |
| Members Guide | Popular profiles, leaderboards, community members | Members API |
| Authentication | Sessions, profile updates, notification management | Auth API |
| Examples & Tools | Ready-to-run CLI utilities, export tools, visualizations | - |
| Development | Environment setup, pytest, Ruff linting, CI/CD | - |