Skip to content

Moid-M/moidify

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

20 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation


Moidify

๐ŸŽต Moidify

Your music. Anywhere. No strings attached.
A self-hosted music server that streams your collection to any browser.
Drop files. Listen instantly. No accounts required. No algorithms. No ads.

๐Ÿš€ Quick Install ยท โœจ Features ยท โš™๏ธ Commands ยท ๐Ÿ”ง Configuration ยท ๐Ÿ› ๏ธ Development



โœจ Features

๐ŸŽง Streaming โ€” MP3, FLAC, OGG, M4A, WAV โ€” everything just works

๐ŸชŸ Pop-out Mini Player โ€” detach playback into a separate always-on-top window (desktop only; mobile uses the persistent bottom bar)

๐Ÿ” Full-text Search โ€” search tracks, albums, artists with diacritics support (Beyonce โ†’ Beyoncรฉ)

๐Ÿ“‚ Browse by Album / Artist / Genre โ€” grid or list view with cover art

๐Ÿ“‹ Sortable Columns โ€” click any column header to sort Aโ€“Z, Zโ€“A, or by duration

๐Ÿ“ Playlists โ€” create, pin, reorder by drag-and-drop

๐ŸŽ›๏ธ 10-Band Equalizer โ€” presets included (Rock, Jazz, Dance, Classicalโ€ฆ)

๐Ÿ“œ Lyrics โ€” auto-fetched from LRCLIB, synced scrolling

โฑ๏ธ Sleep Timer โ€” stop after this track, end of queue, or in X minutes

๐Ÿ”€ Smart Queue โ€” crossfade, shuffle, repeat (all/one/off)

๐Ÿ’พ Session Persistence โ€” close or reload the tab and pick up exactly where you left off (position, queue, shuffle mode all saved)

๐Ÿ’ฟ Vinyl Animation โ€” spinning disc with CD hole effect on the queue cover art (toggle in settings)

๐Ÿ›ก๏ธ Admin Dashboard โ€” rescan library, manage users, view play stats, upload files via drag-and-drop

๐Ÿ”ง Setup Wizard โ€” first-run wizard at /setup creates admin account and guides configuration

๐Ÿณ Docker Support โ€” Dockerfile + docker-compose.yml for containerized deployment

๐Ÿ”— Shareable Playlists โ€” generate a public link anyone can open and listen to (no account needed)

๐Ÿ“ป On-the-fly Transcoding โ€” serve medium (256k), low (128k), or voice (64k Opus) streams via ffmpeg

๐Ÿ  Personalized Home Feed โ€” recently played, top listened, and randomly recommended tracks on login

๐Ÿ”Œ Subsonic API Compatible โ€” works with clients like Sonixd, Sublime Music, and DSub (/rest/getArtists, /rest/getAlbum, /rest/stream, scrobbling, star/unstar, and more)

๐ŸŽฎ Discord Rich Presence โ€” companion script shows your currently playing track on Discord

๐Ÿ“ฑ Responsive โ€” works on desktop and mobile browsers

๐ŸŽš๏ธ Track Rating โ€” rate songs 1-5 stars from the track list or context menu


๐Ÿš€ Quick Install

One line, works on any Linux distro with systemd:

curl -sSL https://raw.githubusercontent.com/Moid-M/moidify/main/install.sh | sudo bash
๐Ÿ“ฆ What the installer does (click to expand)
Step What happens
1 Detects your distro (apt/dnf/pacman/zypper) and installs Python, pip, sqlite3
2 Creates a moidify system user
3 Copies the app to /opt/moidify
4 Sets up a Python virtual environment
5 Installs Python dependencies (FastAPI, uvicorn, mutagen, watchdog)
6 Asks for port number (default 8000)
7 Asks for your music folder location
8 Asks to create an admin account (optional โ€” skip to use the browser setup wizard later)
9 Writes config to /etc/moidify/config.json
10 Installs a systemd service
11 Starts the server immediately

Tip

After installation, open http://your-server-ip:8000 in any browser. If no admin account exists yet, you'll be guided through the setup wizard at /setup. Drop music into your folder โ€” files appear automatically.

Note

Moidify is 100% vibecoded.
Every line was written through natural language prompts โ€” no copy-paste, no templates, just pure AI-generated code. If something breaks (and it might), please open an issue.
It'll get fixed, and the AI will learn from it.


๐Ÿณ Docker

git clone https://github.com/Moid-M/moidify.git
cd moidify
docker compose up -d

Then open http://localhost:8000. Music goes in ./music, data in ./data, covers in ./covers.

Tip

After starting, visit the setup wizard at /setup to create your admin account.

๐Ÿ–ฅ๏ธ Manual Install

For development or non-systemd systems:

git clone https://github.com/Moid-M/moidify.git
cd moidify
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt
python3 server.py

Then open http://localhost:8000.


โš™๏ธ Commands

CLI (moidify)

After install, a moidify CLI is available globally:

moidify help          Show this help
moidify start         Start the service
moidify stop          Stop the service
moidify restart       Restart the service
moidify reload        Reload config and rescan library
moidify status        Show service status
moidify enable        Enable service on boot
moidify disable       Disable service on boot
moidify logs          Tail server logs
moidify config        Print current configuration
moidify version       Print version
moidify url           Print server URL
moidify update        Update to latest version

Service management (direct)

Action Command
โ–ถ๏ธ Start sudo systemctl start moidify
โน๏ธ Stop sudo systemctl stop moidify
๐Ÿ”„ Restart sudo systemctl restart moidify
๐Ÿ“Š Status sudo systemctl status moidify
๐Ÿ“œ Logs journalctl -u moidify.service -f
๐Ÿ”„ Update sudo /opt/moidify/update.sh
๐Ÿ—‘๏ธ Uninstall sudo /opt/moidify/uninstall.sh

๐Ÿ”ง Configuration

Moidify checks three places for settings, in order of priority:

  1. Environment variables (highest priority)
  2. Config file at /etc/moidify/config.json (installed mode)
  3. Local defaults (development mode)

Environment variables

Variable Default (dev) Description
MOIDIFY_MUSIC_DIR ./music Path to your music folder
MOIDIFY_COVERS_DIR ./covers Cover art cache location
MOIDIFY_DB_PATH ./data/music.db SQLite database path
MOIDIFY_PORT 8000 Server port (systemd mode uses ExecStart directly)

Config file

When installed, settings live in /etc/moidify/config.json:

{
  "music_dir": "/path/to/your/music",
  "covers_dir": "/var/lib/moidify/covers",
  "db_path": "/var/lib/moidify/music.db",
  "port": 8000
}

Note

Change a path and restart with sudo systemctl restart moidify โ€” your music collection is re-scanned automatically.


๐ŸŽฎ Discord Rich Presence

Show what you're listening to on your Discord profile:

pip install pypresence
python3 contrib/discord-presence.py --url http://your-server:8000

The script polls Moidify's /api/player/now-playing endpoint and updates your Discord status via RPC. Requires the Discord desktop app running and a Discord Application ID (create one at the Discord Developer Portal).


๐Ÿ› ๏ธ Development

git clone https://github.com/Moid-M/moidify.git
cd moidify
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt
python3 server.py

Tip

The server uses watchdog to monitor your music folder for changes. Drop new files in and they appear instantly โ€” no rescan button needed.

Project structure

moidify/
โ”œโ”€โ”€ contrib/
โ”‚   โ””โ”€โ”€ discord-presence.py   # Discord RPC companion script
โ”œโ”€โ”€ routes/
โ”‚   โ”œโ”€โ”€ __init__.py
โ”‚   โ”œโ”€โ”€ deps.py               # Shared utilities, auth helpers, Pydantic models
โ”‚   โ”œโ”€โ”€ auth.py               # Register, login, me, setup wizard
โ”‚   โ”œโ”€โ”€ tracks.py             # Tracks, albums, artists, genres, home, ratings
โ”‚   โ”œโ”€โ”€ streaming.py          # Transcode, stream, cover art, download album
โ”‚   โ”œโ”€โ”€ playlists.py          # Playlists CRUD, share, folders, favorites, export
โ”‚   โ”œโ”€โ”€ admin.py              # Dashboard, stats, users, rescan scheduler
โ”‚   โ””โ”€โ”€ subsonic.py           # Subsonic API compatibility layer (23 endpoints)
โ”œโ”€โ”€ Dockerfile                # Container image
โ”œโ”€โ”€ docker-compose.yml        # Docker orchestration
โ”œโ”€โ”€ server.py                 # FastAPI app (~80 lines, includes all route modules)
โ”œโ”€โ”€ scanner.py                # File scanner + metadata extractor
โ”œโ”€โ”€ database.py               # SQLite schema + migrations + indexes
โ”œโ”€โ”€ config.py                 # Configuration loader
โ”œโ”€โ”€ install.sh                # System installer script
โ”œโ”€โ”€ uninstall.sh              # Cleanup script
โ”œโ”€โ”€ update.sh                 # Git-pull updater
โ”œโ”€โ”€ moidify.service           # Systemd unit file
โ”œโ”€โ”€ requirements.txt          # Python dependencies
โ”œโ”€โ”€ static/
โ”‚   โ”œโ”€โ”€ index.html            # Main frontend
โ”‚   โ”œโ”€โ”€ setup.html            # First-run setup wizard
โ”‚   โ”œโ”€โ”€ shared.html           # Public shared playlist page
โ”‚   โ”œโ”€โ”€ admin.html            # Admin dashboard
โ”‚   โ”œโ”€โ”€ style.css             # @imports all CSS files
โ”‚   โ”œโ”€โ”€ logo.png              # App logo
โ”‚   โ”œโ”€โ”€ css/                  # Split CSS by feature
โ”‚   โ”‚   โ”œโ”€โ”€ variables.css     # CSS vars, light mode overrides
โ”‚   โ”‚   โ”œโ”€โ”€ layout.css        # App grid, html/body
โ”‚   โ”‚   โ”œโ”€โ”€ sidebar.css       # Nav, playlists, pinned
โ”‚   โ”‚   โ”œโ”€โ”€ main-content.css  # Album/artist grids, track rows
โ”‚   โ”‚   โ”œโ”€โ”€ player.css        # Player bar, seek, volume
โ”‚   โ”‚   โ”œโ”€โ”€ queue.css         # Queue panel
โ”‚   โ”‚   โ”œโ”€โ”€ modal.css         # Overlay + modal
โ”‚   โ”‚   โ”œโ”€โ”€ settings.css      # Settings layout, toggles, EQ
โ”‚   โ”‚   โ”œโ”€โ”€ context-menu.css  # Right-click menu
โ”‚   โ”‚   โ”œโ”€โ”€ nowplaying.css    # Now-playing overlay
โ”‚   โ”‚   โ”œโ”€โ”€ overlays.css      # Fullscreen art, EQ panel, etc
โ”‚   โ”‚   โ”œโ”€โ”€ animations.css    # All keyframes
โ”‚   โ”‚   โ”œโ”€โ”€ features.css      # Misc feature styles
โ”‚   โ”‚   โ”œโ”€โ”€ mini-player.css   # Mini player
โ”‚   โ”‚   โ”œโ”€โ”€ toast.css         # Toast notifications
โ”‚   โ”‚   โ””โ”€โ”€ responsive.css    # All @media queries
โ”‚   โ””โ”€โ”€ js/
โ”‚       โ”œโ”€โ”€ state.js          # App state + utility functions
โ”‚       โ”œโ”€โ”€ icons.js          # SVG icon library
โ”‚       โ”œโ”€โ”€ api.js            # API client + auth + favorites + playlists
โ”‚       โ”œโ”€โ”€ i18n.js           # Internationalization (English/German)
โ”‚       โ”œโ”€โ”€ player.js         # Audio engine + EQ + transcoding
โ”‚       โ”œโ”€โ”€ queue.js          # Queue management + shuffle
โ”‚       โ”œโ”€โ”€ lyrics.js         # Lyrics fetching + synced display
โ”‚       โ”œโ”€โ”€ animations.js     # Visual effects (vinyl spin, CD hole, glow)
โ”‚       โ”œโ”€โ”€ app.js            # Event binding + session persistence + init
โ”‚       โ”œโ”€โ”€ ui/               # Split UI helpers
โ”‚       โ”‚   โ”œโ”€โ”€ toast.js
โ”‚       โ”‚   โ”œโ”€โ”€ modal.js
โ”‚       โ”‚   โ”œโ”€โ”€ settings.js
โ”‚       โ”‚   โ”œโ”€โ”€ context-menu.js
โ”‚       โ”‚   โ”œโ”€โ”€ eq-panel.js
โ”‚       โ”‚   โ”œโ”€โ”€ sleep-timer.js
โ”‚       โ”‚   โ””โ”€โ”€ search.js
โ”‚       โ””โ”€โ”€ views/            # Split page renderers
โ”‚           โ”œโ”€โ”€ home.js
โ”‚           โ”œโ”€โ”€ albums.js
โ”‚           โ”œโ”€โ”€ artists.js
โ”‚           โ”œโ”€โ”€ tracks.js
โ”‚           โ”œโ”€โ”€ playlists.js
โ”‚           โ”œโ”€โ”€ genres.js
โ”‚           โ”œโ”€โ”€ search.js
โ”‚           โ””โ”€โ”€ navigate.js
โ””โ”€โ”€ music/                    # Your music goes here (local dev)

๐Ÿ“ธ Screenshots

Screenshots coming soon.

๐Ÿ–ฅ๏ธ Desktop (click to expand)
Homepage
Home feed

Albums
Album browser

Artists
Artist grid

All Tracks
Track list with sortable columns

Genres
Genre browsing

Lyrics
Synced lyrics overlay

Settings
Settings modal with equalizer
๐Ÿ“ฑ Mobile (click to expand)
Homepage
Home feed

Albums
Album browser

Artists
Artist grid

Tracks
Track list

Genres
Genre browsing

Lyrics
Lyrics view

Now Playing
Now playing

๐Ÿงฉ Tech Stack

Layer Technology
Backend Python + FastAPI + uvicorn
Frontend Vanilla JavaScript (no framework, no build step)
Database SQLite (via sqlite3) with WAL mode
Metadata Mutagen
File watching watchdog
Transcoding ffmpeg โ€” Opus, MP3, FLAC, WAV
Subsonic API Built-in /rest/* endpoints for third-party clients

๐Ÿ“„ License

This project is open source โ€” you are free to use, modify, share, sell, or do absolutely anything you want with it. No strings attached.

MIT


Made with โค๏ธ + ๐Ÿค– for people who love their music collection.

๐Ÿ› Report a bug ยท ๐Ÿ’ก Request a feature

About

A free and open source Self-hosted music server

Topics

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors