Logo
Kythia
Logo
Kythia
Login
Login
Setup Guide
Minimized (Click to Restore)

Setup Guide

Follow these steps to install, configure, and launch Kythia in your own environment.


This guide will walk you through the process of getting Kythia up and running on your own server. Whether you're setting up for development or production, we've got you covered.


Prerequisites

Before you start, make sure your environment meets these requirements:

  • Node.js: v22.0.0 or higher. We highly recommend using the LTS version.
  • Package Manager: npm, pnpm, or bun.
  • Database: A MySQL or PostgreSQL database instance.
  • Git: Required for cloning the repository.
We recommend using Bun for development as it provides much faster startup times and out-of-the-box TypeScript support.

Installation Steps

1
Clone the Repository

Grab the source code from GitHub.

git clone https://github.com/XXXXXX/XXXXXX.git kythia-bot
cd kythia-bot
2
Install Dependencies

Use your preferred package manager to install the required libraries.

bun install
npm install
pnpm install
3
Environment Configuration

Copy the example environment file and fill in your details.

cp example.env .env

Open the .env file and fill in all your details. Read more about each variable in the Environment Variables.

4
Kythia Configuration

Initialize your main configuration file.

cp example.kythia.config.js kythia.config.js

Check out the Settings Guide for a deep dive into customization options.

5
Database Migration

Prepare your database schema and seed initial data.

npx kythia db seed
6
Deploy Slash Commands

Register your commands with Discord so they appear in the slash menu.

npx kythia deploy

Starting the Bot

Once everything is configured, you can launch Kythia.

Runs the bot with automatic reloading.

npm run dev

Recommended for 24/7 hosting using PM2.

npm run pm2:startup
# Managed via the Kythia CLI
npx kythia pm2 start

Troubleshooting

If you encounter issues during setup:

  • Double-check your .env values (especially the database connection).
  • Ensure your Discord Bot has the necessary Intents enabled in the Developer Portal.
  • Join our Discord Support Server for help.
Kythia Documentation Sign in →