Skip to content
Nexus334023KPublic

About

An Ad-Blocker for Spotify

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 

Repository files navigation

🎵 Spotify Ad Blocker (Web & Desktop)

A lightweight, dual-action solution for a cleaner Spotify experience. This project blocks audio ads, tracking, and visual distractions on both the Spotify Web Player and the Spotify Windows Desktop Application.


✨ Features

🌐 Web Player (Chrome Extension)

  • Audio Ad Blocking: Intercepts and blocks audio ad requests before they play.
  • Visual Ad Removal: Automatically hides banner ads and "Upgrade to Premium" buttons/prompts.
  • Dynamic Protection: Uses a MutationObserver to ensure new ad elements are hidden as they appear.

🖥️ Desktop Application (PowerShell Script)

  • Host-Level Blocking: Redirects known Spotify ad and tracking domains to 0.0.0.0 via the Windows hosts file.
  • Comprehensive Domain List: Blocks over 40+ domains responsible for audio ads, banners, and analytics.
  • Easy Deployment: A simple PowerShell script that backups your existing hosts file and flushes DNS for immediate effect.

🚀 Installation & Usage

1. Web Player Extension

  1. Open Chrome or any Chromium-based browser (Edge, Brave, etc.).
  2. Navigate to chrome://extensions/.
  3. Enable Developer mode (toggle in the top right).
  4. Click Load unpacked and select the /extension folder from this repository.
  5. Enjoy an ad-free web player!

2. Desktop Application Script

Important

This script requires Administrator privileges to modify the Windows hosts file.

  1. Locate spotify_blocker.ps1.
  2. Right-click the file and select Run with PowerShell.
  3. If prompted for permissions, select Yes.
  4. Restart your Spotify desktop app to apply the changes.

🛠️ Project Structure

  • /extension: The Chrome extension files (manifest.json, content.js, etc.).
  • spotify_blocker.ps1: The PowerShell script for desktop ad blocking.

⚠️ Disclaimer

This project is for educational purposes only. Blocking ads may violate Spotify's Terms of Service. Use at your own risk.


🤝 Contributing

Feel free to open issues or submit pull requests with updated ad domains or improved CSS selectors!

About

An Ad-Blocker for Spotify

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages