Analyze your Spotify listening history with rich terminal output. Processes your Spotify privacy data export and generates detailed statistics about your listening habits, favourite artists, tracks, albums, and temporal patterns.
| Feature | Description |
|---|---|
| Rich terminal output | Polished tables, panels, and bar charts using Rich |
| Interactive TUI | Browse sections with keyboard navigation using Textual |
| Pre-computed analysis | All stats computed upfront — no pauses between sections |
| Spotify API integration | Fill gaps in your data with recent plays from the API |
| Export | Save your full history and analysis to JSON or CSV |
| Multi-platform binaries | Download and run without installing Python |
Download the latest binary for your platform from Releases:
| Platform | Binary |
|---|---|
| Linux x86_64 | spotify-insights-linux-x86_64 |
| macOS (Apple Silicon) | spotify-insights-macos-aarch64 |
| Windows x86_64 | spotify-insights-windows-x86_64.exe |
# Linux/macOS
chmod +x spotify-insights-*
./spotify-insights-linux-x86_64 -d /path/to/spotify-data
# Windows
spotify-insights-windows-x86_64.exe -d C:\path\to\spotify-datagit clone https://github.com/zachlagden/Spotify-Listening-Insights.git
cd Spotify-Listening-Insights
pip install -e .spotify-insights -d /path/to/spotify-data
# or
python -m spotify_insights -d /path/to/spotify-data- Go to your Spotify Account Privacy Settings
- Scroll down and request Extended streaming history
- Wait for the email from Spotify (can take up to 30 days)
- Download and extract the ZIP — you will get a folder with JSON files
- Point
spotify-insightsat that folder
spotify-insights [OPTIONS]
Options:
-d, --directory PATH Path to directory containing Spotify JSON files
-o, --output [static|interactive|export]
Output mode (default: prompted)
--export-format [json|csv]
Export format (default: json)
--no-api Skip Spotify API integration
--version Show version
--help Show this message
- static — Print the full report to the terminal with Rich formatting
- interactive — Open a TUI where you can browse sections with arrow keys
- export — Save your full history and analysis summary to JSON or CSV
To fill gaps between your data export and now, you can connect to the Spotify API:
- Go to the Spotify Developer Dashboard
- Create a new application
- Set the redirect URI to
http://localhost:8888/callback - Create a
.envfile in your working directory:
SPOTIFY_CLIENT_ID=your_client_id_here
SPOTIFY_CLIENT_SECRET=your_client_secret_here
pip install -e ".[dev]"
ruff check src/ tests/
ruff format --check src/ tests/
pytest- All data is processed locally on your machine
- No data is sent to external servers
- API credentials are stored locally in
.envand never committed
MIT -- Zachariah Michael Lagden