discord-hosting.cloud
20% Off First MonthSee prices

Bot RAM calculator

How much RAM does my Discord bot need?

Enter your bot and get an estimate with the plan that fits. The method is written out below.

Estimated RAM128 MB
  • Runtime and library90
  • Cache for your servers6
  • Headroom for spikes29

Plan that fits
Small bot512 MB RAM
$0.99$0.79/mofor the first month, then $0.99/mo
Order Small bot

This also fits the free tier (512 MB), which stays online while you check in once a week.

Examples

Common bots and what they need.

BotLibraryServers the bot is inEstimated RAMPlan that fits
Personal bot in 5 serversdiscord.js (Node.js)5128 MBSmall bot
Moderation bot for one 1,000+ member serverdiscord.py / py-cord / nextcord1128 MBSmall bot
Public bot in 400 serversdiscord.js (Node.js)400384 MBSmall bot
Music bot with Lavalinkdiscord.js (Node.js)50704 MBCommunity bot
Sharded bot in 6,000 serversdiscord.js (Node.js)6,0001,344 MBCommunity bot
JDA bot in 200 serversJDA (Java)200448 MBSmall bot

Methodology

How the estimate works.

A rough model from common experience with Discord bots. Your code and caches decide the real number, so watch memory in the panel.

  1. Runtime. The language runtime and library at idle: about 90 MB for discord.js, 70 MB for discord.py, 220 MB for JDA on the JVM, 30 MB for Go or Rust.
  2. Cache. Memory per server grows with how much you cache and how big servers are: minimal caching keeps almost nothing, full member and presence caching keeps every member.
  3. Sharding. From 2,500 servers Discord requires shards, about one per 1,000 servers. discord.js ShardingManager runs one process per shard (one runtime each); discord.py and JDA share one process.
  4. Voice. Lavalink is a Java audio server that needs about 450 MB on its own. Audio encoded in the bot with FFmpeg adds a base plus a little per active server.
  5. Headroom. We add 30% for spikes and garbage collection, then pick the smallest plan with at least that much RAM.

This is an estimate, not a guarantee. A memory leak, large message caches or heavy image processing can change the numbers. Plan changes are prorated.

See all plans Sharding guide

Why does my bot use more RAM over time?

Caches fill as the bot sees more members, messages and channels. Limit caches in your library's options; memory that keeps growing without limit is usually a leak.

Does the Server Members intent cost memory?

It lets the bot receive and cache every member, which is the biggest memory cost for bots in large servers. Only enable it if you need member lists.

Is 512 MB enough?

For most bots in up to a few hundred small servers without voice, yes. Music bots with Lavalink and sharded bots need more.