Ever been on a music site that has all the songs but no "play next" button? Auto Audio Player fixes that — silently, automatically, on any website.
- Auto Next — When a track ends, the next
<audio>on the page plays instantly - Works Everywhere — No site-specific code; if it uses a standard
<audio>tag, this works - Dynamic Page Support — Uses
MutationObserverto catch audio elements loaded after page render - Smooth Scroll — Automatically scrolls to the currently playing track
- Persistent State — Remembers if you had it enabled, even after closing the browser
- Zero Config — One toggle. That's it.
- Lightweight — No dependencies, no frameworks, pure vanilla JS (~100 lines)
| Popup UI | Active on Page |
|---|---|
![]() |
![]() |
- Clone the repo
git clone https://github.com/rezamqds/AudioAutoPlay.git
cd AudioAutoPlayPage Loads
│
▼
content.js injects into the page
│
▼
Queries all elements
│
▼
Attaches ended event listener to each
│
▼
MutationObserver watches for new audio elements
│
▼
Track ends → next track plays → page scrolls to it
The extension uses a clean IIFE pattern with no global scope pollution. State is managed via chrome.storage.local and communication between popup and content script is handled through chrome.runtime.onMessage.
auto-audio-player/ │ ├── manifest.json # Extension config (Manifest V3) ├── content.js # Core logic — injected into every page ├── popup.html # Extension popup UI ├── popup.js # Popup logic & tab communication │ └── icons/ ├── icon16.png ├── icon48.png └── icon128.png
| Layer | Tech |
|---|---|
| Extension API | Chrome Manifest V3 |
| Content Script | Vanilla JavaScript (ES6+) |
| DOM Observation | MutationObserver API |
| State Persistence | chrome.storage.local |
| UI | HTML + CSS (no framework) |
Contributions are welcome. Please open an issue first to discuss what you'd like to change.
bash
git checkout -b feature/your-feature git commit -m "feat: add your feature" git push origin feature/your-feature
See CONTRIBUTING.md for details.
MIT © rezamqds
If this saved you from clicking "Next" a hundred times, consider giving it a ⭐


