A comprehensive tool for analyzing your Spotify listening history data. This tool processes your exported Spotify data and optionally connects to the Spotify API to provide detailed insights into your music listening patterns.
- 📊 Comprehensive listening statistics
- 🎵 Detailed track analysis
- 👥 Artist listening patterns
- 💿 Album play statistics
- ⏰ Temporal listening patterns
- 📈 Advanced metrics and trends
- 🔄 Recent plays integration via Spotify API
- 📤 Export capabilities for processed data
- Naivgate to the latest release from GitHub Releases
- Download the
spotify_analyzer.exe
file.
Please note: Windows may flag the executable as a security risk. You can bypass this by clicking "More Info" and then "Run Anyway". This is because the executable is not signed.
- Create a
.env
file in the same folder as the executable with your Spotify API credentials (if using API features):
SPOTIFY_CLIENT_ID=your_client_id_here
SPOTIFY_CLIENT_SECRET=your_client_secret_here
- Double-click the executable to run the analyzer
Required Python Libraries:
pandas
spotipy
tqdm
python-dotenv
- Clone this repository:
git clone https://github.com/zachlagden/spotify-listening-analyzer.git
cd spotify-listening-analyzer
- Install required packages:
pip install -r requirements.txt
- Run the analysis:
python spotify_analyzer.py
- Go to your Spotify Account Privacy Settings
- Request your data export (Extended streaming history)
- Wait for the email from Spotify (can take up to 30 days)
- Download and extract the JSON files
- Go to the Spotify Developer Dashboard
- Create a new application
- Get your Client ID and Client Secret
- Create a
.env
file as described above
- Total listening time
- Daily averages
- Unique tracks/artists/albums
- Active listening days
- Weekend vs. weekday patterns
- Top artists by listening time
- Artist-specific statistics
- Listening patterns per artist
- First/last played dates
- Most played tracks
- Play counts and durations
- Listening patterns
- Track popularity over time
- Most played albums
- Album completion rates
- Listening patterns
- Album lifecycle information
- Time of day distribution
- Day of week patterns
- Monthly listening trends
- Seasonal preferences
- Listening consistency scores
- Listening streaks
- Daily statistics
- Activity patterns
📊 Overall Statistics:
• Total listening time: 1,234.5 hours (51.4 days)
• Daily average: 127.3 minutes
• Unique tracks: 3,456
• Active listening days: 280 (76.7% of period)
🎸 Top Artist Example:
• Artist Name
- Total Time: 45.6 hours
- Tracks: 123 unique across 8 albums
- Weekend Listening: 65.4% of plays
- All data is processed locally
- No data is sent to external servers
- API credentials are stored locally in
.env
- Original data files are never modified
-
Missing JSON Files
- Ensure you've extracted all files from the Spotify data export
- Check file permissions
-
API Connection Issues
- Verify your
.env
file configuration - Check your internet connection
- Ensure API credentials are correct
- Verify your
-
Processing Errors
- Check JSON file formatting
- Ensure sufficient disk space
- For executable users: Make sure the
.env
file is in the same directory as the exe
- Create an issue in the repository
- Check existing issues for solutions
- Include error messages and system details
- Fork the repository
- Create a feature branch
- Commit your changes
- Push to the branch
- Create a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Thanks to Spotify for providing user data export
- Built with Python and various open-source libraries
- Inspired by the music analysis community
Created by Zachariah Michael Lagden © 2024 - MIT License