Repository navigation
v1.0.0
A single-page, self-hosted Last.fm dashboard with live theming, period-switchable stats, and a set of data-driven insight widgets.
✨ Highlights
- Now Playing hero — live "now scrobbling" / last-played track, polled every ~10 seconds, with independent Track and Album artwork tiles (they're fetched separately and can differ).
- Dynamic theming — the page background and accent colour are extracted live from the current track's album art and eased in over a smooth transition. The accent colour is clamped to a safe WCAG luminance band so text stays readable regardless of how light or dark the source artwork is.
- Favourite Tracks, Trending, and Genre Breakdown panels, each with an All Time / This Year / This Month / Today period picker, switched instantly via AJAX with no page reload.
- Lifetime Stats — total scrobbles, unique artists/albums/tracks, average scrobbles/day, and member-since date, ticking up live as new scrobbles land rather than only refreshing on page load.
- Eight insight widgets, opened as popups from clickable cards:
- Listening Clock — a 24-hour radial chart of when you actually listen, labeled by dominant period (e.g. "Night Owl", "Dawn Chorus")
- Energy Curve — real scrobble-activity volume across the week (clearly labeled as activity, not audio tempo — Last.fm has no tempo data)
- Distance Listened — estimated total listening time converted into flights, marathons, laps of the Earth, and — for heavy listeners — trips to the Moon or Mars
- If Your Year Were a Festival — your top artists billed as a tiered festival poster lineup
- Mood Weather — a monthly emotional "forecast" derived from your top artists' community tags
- BPM Average — real average tempo sourced from Deezer's free public API, since Last.fm exposes none
- Before They Were Famous — your favourite artists with the lowest current global Last.fm listener counts
- Obscurity Index — the average and median global listener count across your top artists
- Self-update check — the footer compares the installed version against the latest GitHub release and links to it when an update is available, with a GitHub icon/link alongside the version number.
🔧 Under the hood
- File-based caching throughout, with TTLs tuned per data type (seconds for now-playing polling, a day for genre/track-art lookups, a week for artist metadata) — most repeat page loads resolve in single-digit milliseconds.
- Graceful
curl→file_get_contentsfallback for hosts without the curl extension. .htaccess/.user.iniincluded for toggling PHP error display between debug and production on shared hosting.- All external API calls (Last.fm, Deezer, GitHub) are cached independently and fail gracefully with clear empty/error states rather than fatal errors.
📄 Documentation & Licensing
- Added a full project
README.mddescribing setup, requirements, and every feature above. - Licensed under GPL-3.0 (
LICENSE).
🐛 Fixes
- Corrected the dynamic accent-color extraction so text always remains legible against album-art-derived backgrounds and buttons, regardless of how light, dark, or saturated the source image is.