Spotify like dynamic gradient background based on image colours

Worried about licensing?

Do you have right license for your templates and fonts?

Head over to our partner Envato Elements and unlock unlimited downloads of over 50 million digital assets with full commercial licensing.

  • 50+ Million Assets with Unlimited Downloads
  • Templates, Addons, Fonts, Footage, Photos, Brushes, Presets & More
  • Full Commercial licensing for client work

Get ultimate peace of mind!

Get Started Now
Image: Spotify like dynamic gradient background based on image colours GIF

Ever wanted that dynamic background gradient colour that comes up in Spotify? Now you can get that same effect for you images with this pure CSS snippet. As you can see below, depending on the image there is a background gradient glow around that image using the primary colours of that image.

If you like this you might like more of our deconstruction snippets.

If you are having trouble with the pen, try the archived copy on GitHub and here is the one with 2 images side by side.

Spotify Background Gradient Snippet

See the Pen eYYvwWb by Saijo George (@SaijoGeorge) on CodePen.0

See the Pen GRRWWze by botch (@plasmatic) on CodePen.0

Posted by:Saijo George

Digital Marketer with a strong focus on technical SEO and design. One of the top 100 makers on Producthunt, co-organizer of the SEO Meetup in Melbourne, an instructor at General Assembly. Worked with brands like Envato, AEON. Currently the SEO Strategy Director at Supple.