This guide is for bots packaged as a single runnable jar, for example built with JDA.
Switch the server to Java
A new bot server starts as a Node.js server. Change it before you upload anything, because changing the type reinstalls the server and by default deletes its files.
- Open your server in the panel and stay on Overview.
- Click Edit Server Type and choose Java Bot. See How to change your server type or game version for the full walkthrough.
Add your jar
- Build a jar that runs on its own, with its dependencies included (a "fat" or "shaded" jar).
- Open Files and upload it.
- Open Settings, then Game Settings, and set Jar file to the name of your jar, for example
bot.jar. - Paste your token into Discord bot token (optional). Your code reads it with
System.getenv("DISCORD_TOKEN").





