NOWOŚĆ 📢 Zaoszczędź do 30% w pierwszym miesiącu, oferta ograniczona czasowo!

How much RAM does a Discord bot need?

Discord bot hostingUpdated Oct 6, 20263 min read

There is no single number. Memory depends on the language, how many Discord servers the bot is in, and how much it keeps in memory. These are rules of thumb; your own graph is the real answer.

Starting points

BotStarting plan
A small bot for your own server or a few friends' servers, slash commands only512 MB
A bot in a few dozen servers, with a database and some caching1 GB
A busy bot in hundreds of servers, or one that caches members and messages2 GB
A large bot, or one that handles music or images4 GB and up
Very large bots, sharded across many servers8 GB

Java uses more memory than Node.js or Python for the same job, so start one step higher for a Java bot. A ready-made music bot such as Red, Muse or JMusicBot is happiest on 1 GB or more.

What makes a bot use more

  • Caching. Libraries keep servers, members and messages in memory. Turning off caches you do not use is the cheapest fix.
  • More servers and members. Every server the bot joins adds to the cache.
  • Intents. Server Members and Presence intents load many more objects.
  • Memory leaks. Memory that climbs steadily and never drops after restarts usually means a leak in the code, such as a list that only grows.

Check your usage

Open your server in the panel. On Overview, the Usage card has CPU, RAM and Storage tabs with a live graph and the current figure against your limit. Look at it after the bot has been running a day, not just right after a start.

If you run out

A bot that reaches its memory limit is stopped by the server and the console may show nothing useful. Read Why your Discord bot keeps stopping. To get more memory you can move to a bigger plan from your account; the server keeps its files.

STWÓRZ SWÓJ SERWER GIER
GOTOWY, ABY ZACZĄĆ?

Oszczędź nawet 30% na swoim nowym serwerze gier.
Wydajność premium, natychmiastowa aktywacja i niezawodność bez kompromisów. Wszystko w lepszej cenie.

NASZE OSTATNIE WPISY