Self-hosted · Discord voice · Music

Find your server’s rhythm.

Lofi is a self-hosted Discord music bot that keeps the room playing—choose an online station, your own local library, or an original beat rendered on the machine running it.

  • Python
  • Windows · macOS · Linux
  • Self-hosted
  • MIT licensed
Four audio pathsStreams, local files, and generated music
Your own instancePlayback and dashboard run on your host
Slash-command controlsNo privileged Discord intents required

Pick a source

One bot. Four ways to play.

Mix and match the built-in station types or add a source you control. Network stations depend on the provider and connection; local and generated audio can run without an internet connection to the source.

Broadcasts

Play supported YouTube live broadcasts such as Lofi Girl, Chillhop, and Synthwave Boy, with reconnect handling for streams.

Radio streams

Add SomaFM ambient channels or another compatible HTTP(S) audio stream. The configured host connects to the source.

Your own library

Shuffle audio files from a local folder on the bot host. The folder is yours to manage and does not need a music service account.

Studio Lofi

Generate original instrumental tracks on the host itself. No network stream or third-party recording is needed for this station.

Installation & Setup

Deploy Lofi in your voice channel.

Runs on Python 3.9+ with FFmpeg. Play stream presets, local MP3s, or offline algorithmic beats.

Installation Steps

  1. 1. Clone the repository

    git clone https://github.com/mob5824m-wq/Discord-lofi.git && cd Discord-lofi
  2. 2. Install requirements & verify audio

    pip install -r requirements.txt && python3 bot.py --check
    Requires FFmpeg installed on the host system.
  3. 3. Configure Bot Token

    export DISCORD_TOKEN="your-bot-token"
  4. 4. Start Lofi

    python3 bot.py
    Or run python3 bot.py --demo to test the web dashboard without a bot token.

How to Use

  1. 1. Join a voice channel

    Join any voice channel in your Discord server.

  2. 2. Play streams or stations

    /play station:SomaFM
    Use /play stream:<url> or /play local for host MP3s.
  3. 3. Offline Studio Lofi

    /play studio
    Synthesizes and renders original lofi beats directly on the machine without internet.
  4. 4. Web Dashboard

    Open http://localhost:8080 with your dashboard access token to manage queue, station presets, and playback history.

More than a play button

Keep listening simple to run.

01 / CONTROL

Commands where you need them

Use Discord slash commands for stations, queues, playback, volume, and per-server setup.

02 / DASHBOARD

Manage the details

The token-protected dashboard shows current playback, station settings, and listening history. It binds to the local machine by default.

03 / CONTINUITY

Let the music run

Configure autostart, idle disconnect, announcements, and channel status to suit your server.

Run Lofi on your own machine

Releases include installers and portable builds. Review the setup guide, secure your bot token, and check the music rights and service terms that apply to your sources.

Browse releases