---
title: "Deploy Discord4J Bot"
description: "A template for deploying Discord bots with Discord4J"
category: "Bots"
url: https://railway.com/deploy/GnBRzM
---

# Deploy Discord4J Bot

A template for deploying Discord bots with Discord4J

**[Deploy Discord4J Bot on Railway](https://railway.com/template/GnBRzM)**

Machine-readable deploy manifest (JSON, validated by TemplateCI): https://railway.com/deploy/GnBRzM/manifest.json

- **Creator:** Lelebees's Projects
- **Category:** Bots
- **Total deploys:** 13

## Template content

### Discord Bot

- **Source:** https://github.com/Lelebees/railway-d4j-template

## Documentation

This is a template for deploying Discord4J bots on Railway. It is based on the example Maven / Spring project from
the [example repository](https://github.com/Discord4J/example-projects)

In order to start, you should have made a bot in the [Discord Developer Portal](https://discord.com/developers). You will need the bot's key in order to deploy this template. Don't share the key with anyone!

If you wish to test locally, you can make a .env file with a `BOT_TOKEN` variable. I recommend using a separate bot user for testing and production.

## Similar templates

- [Swarm](https://railway.com/deploy/swarm) — Named LLM bots join channels, take jobs, run routines on your Railway box
- [Telegram JavaScript Bot](https://railway.com/deploy/5lRkWa) — A template for Telegram bot in JavaScript using grammY
- [Cobalt Tools [Updated Oct ’26]](https://railway.com/deploy/cobalt) — Cobalt Tools [Oct ’26] (Media Downloader, Converter & Automation) Self Host

Open this page in a browser: https://railway.com/deploy/GnBRzM
