Discord bots ยท music

Discord music bot hosting on the Pro tier

A music bot decodes and re-encodes audio in real time, which is why it does not fit a 256 MB container. It runs here on the Pro tier, with FFmpeg and Opus in the runtime. We ship no music template, and this page says why.

Tier
Pro: 4 GB, 3 vCPU, $6/mo
Runtime
FFmpeg, Opus, libsodium included
Template
None; bring your repository
Lavalink
One click from the app catalog, Starter and up

What runs

discord.js with @discordjs/voice, discord.py with voice extras, Lavalink-based bots: the runtime has FFmpeg, libopus and libsodium, so voice works out of the box. Give the bot the Pro tier. Transcoding one stream sits comfortably in it; a bot playing in many servers at once wants Lavalink, which runs as its own app (one click from the app catalog on a Starter plan, from the official image) with the bot pointed at it over the private network.

Why there is no music template

Every music template depends on pulling audio from platforms whose terms forbid it, and playback from data centre addresses is increasingly blocked by the largest of them. A template we maintained would stop working without warning and send people to us for a fix we cannot ship. If you run your own music bot with sources you are entitled to use, it runs fine here; we just do not put our name on one.

Sizing

UseTier
One server, one stream at a timePro, $6
A few serversPro for the bot, plus a Lavalink app on Standard or Pro
Public music bot in hundreds of serversNot a fit for a $6 container; a VPS or several Lavalink nodes

Frequently asked questions

Can I host a music bot for free?

No. Audio transcoding does not fit 256 MB; the Pro tier ($6 a month) is where music bots run.

Is FFmpeg installed?

Yes, with libopus and libsodium. Bots that ship their own FFmpeg binary work too on paid tiers.

Does YouTube playback work?

Sometimes, and less each year: playback from data centre addresses is increasingly blocked. Bots that play from sources you host or license work reliably.

Can I run Lavalink?

Yes, as its own app on a paid tier; the bot reaches it by name over the private network.

Related

Discord music bot hosting on the Pro tier

Host a bot