Setup guide

From zero to first clone

Nine steps. Roughly fifteen minutes the first time. Every command below has a copy button — hover over the block.

  1. Check your requirements

    You need Python 3.10 or newer and administrator rights on both servers — the one you copy from and the one you copy to.

    check python
    # Windows
    python --version
    
    # macOS / Linux
    python3 --version

    Anything below 3.10 or a “command not found”? Install Python from python.org. On Windows, tick “Add Python to PATH” during installation.

    💡

    No target server yet? In Discord, click + at the bottom of the server list → Create My Own. An empty server is the ideal target.

  2. Create the application

    Open the Discord Developer Portal and sign in with your Discord account.

    • Top right → New Application
    • Name it, e.g. Easy Server Cloner
    • Accept the terms → Create
  3. Get your bot token

    In the left menu go to Bot. Next to the token field, press Reset Token and confirm. Copy what appears.

    🔐

    The token is shown exactly once. Lose it and you simply reset again. Never share it and never commit it — anyone holding the token has full control of your bot.

    While you are on this page, set two things:

    • Public Bot → turn off, so nobody else can invite your cloner.
    • Privileged Gateway Intents → leave all off. You only need them for the optional extras.

    Press Save Changes.

  4. Invite the bot to both servers

    Left menu → OAuth2OAuth2 URL Generator.

    Scopes

    • bot
    • applications.commands

    Bot permissions

    • Administrator

    Copy the Generated URL at the bottom and open it in your browser. Pick a server → ContinueAuthorize. Do this twice — once for the source server, once for the target.

    Why Administrator? Discord only lets a bot grant permissions it holds itself. With anything less, your copied roles would arrive stripped of exactly the permissions you cared about.

  5. Move the bot's role to the top

    This is the step almost everyone skips, and it decides how your result looks.

    Discord never lets a bot create roles above its own. If the bot sits at the bottom of the list, every copied role lands below it and your whole hierarchy comes out flattened.

    On the target server: Server SettingsRoles → drag Easy Server Cloner all the way up.

    role order
       Before                      After
       ──────────                  ──────────
       Admin                    🤖 Easy Server Cloner  ← top
       Moderator                   Admin
       Member                      Moderator
       🤖 Easy Server Cloner       Member
  6. Install the project

    terminal
    git clone https://github.com/aquaxs1/Easy-Cloner.git
    cd Easy-Cloner
    pip install -r requirements.txt

    Prefer keeping your system Python clean? Use a virtual environment:

    virtual environment
    python -m venv .venv
    
    # macOS / Linux
    source .venv/bin/activate
    
    # Windows
    .venv\Scripts\activate
    
    pip install -r requirements.txt
  7. Configure your .env

    copy the template
    # macOS / Linux
    cp .env.example .env
    
    # Windows
    copy .env.example .env

    Open the new .env in any editor and fill in three lines:

    .env
    # Required — from the Developer Portal
    DISCORD_TOKEN=your.real.token.here
    
    # Recommended — only you may run the bot
    OWNER_IDS=123456789012345678
    
    # Recommended — commands appear instantly instead of in ~1 hour
    DEV_GUILD_ID=987654321098765432
    🆔

    Finding IDs: Discord → SettingsAdvanced → enable Developer Mode. Then right-click yourself → Copy User ID, or right-click a server icon → Copy Server ID.

    .env is git-ignored by default, so your token can never travel to GitHub by accident.

  8. Start the bot

    terminal
    python main.py

    If everything is right, you will see:

    output
      ______                     _____ _
     |  ____|                   / ____| |
     | |__   __ _ ___ _   _    | |    | | ___  _ __   ___ _ __
     |  __| / _` / __| | | |   | |    | |/ _ \| '_ \ / _ \ '__|
     | |___| (_| \__ \ |_| |   | |____| | (_) | | | |  __/ |
     |______\__,_|___/\__, |    \_____|_|\___/|_| |_|\___|_|
                       __/ |     Easy Server Cloner v2.1.0
                      |___/      Discord Server Structure Cloner
    
    14:32:01  INFO   Slash commands registered for dev guild.
    14:32:02  INFO   Logged in as Easy Server Cloner#1234
    14:32:02  INFO   Active on 2 server(s).

    Keep the window open — the bot is online for as long as it runs. Stop it with Ctrl + C. For permanent hosting, see Docker below.

  9. Run your first clone

    Switch to Discord and type / — the bot's commands appear.

    a · Look around

    discord
    /servers

    Lists every server the bot can reach. 👑 means ready, ⚠️ means missing permissions.

    b · Back up first

    discord
    /backup

    Pick your source server from the suggestion list — you never type IDs, the bot offers every server it can see. Keep the file it hands back.

    c · Dry run

    discord
    /preview  source: <source server>  target: <target server>

    Shows exactly what would be copied, what would be deleted, and roughly how long it takes. Changes nothing. Read it carefully.

    d · Clone

    discord
    /clone  source: <source server>  target: <target server>

    A confirmation appears with all the numbers. Nothing happens until you press 🧬 Clone now. Then a live progress bar runs, with a 🛑 Cancel button you can hit at any moment.

    e · Finish by hand

    Three things no bot can do for you:

    1. Sort the role hierarchy. Every copied role sits below the bot's role — drag them into place.
    2. Invite your members. People have to join themselves.
    3. Enable Community features if the source had them — rules channel, onboarding, stage channels.
    🎉

    Done. Your target server is now a copy of the source.


Run it permanently with Docker

So you do not have to keep a terminal open:

terminal
cp .env.example .env      # fill in your token
docker compose up -d
managing it
docker compose logs -f    # watch the logs
docker compose restart    # after editing .env
docker compose down       # stop

The backups/ and state/ folders are mounted as volumes and survive restarts. The container runs as its own user, not root.

Optional extras

Two features need privileged intents. Only switch them on if you actually want them — both make a run noticeably slower.

⚠️

If a switch is true in your .env but the matching intent is off in the Developer Portal, Discord refuses the login entirely. Always flip both together.

Rebuild messages

Replays the last n messages per channel through a webhook, with the original name and avatar.

ℹ️

This is a reconstruction, not a migration. The messages look genuine but come from a webhook — reactions, threads and edit history stay behind.

  1. Developer Portal → Bot → enable Message Content Intent → Save
  2. In .env: ENABLE_MESSAGE_CLONE=true
  3. Restart the bot
  4. Run /clone messages:100

Reassign member roles

Gives members who are on both servers the same roles in the target.

  1. Developer Portal → Bot → enable Server Members Intent → Save
  2. In .env: ENABLE_MEMBER_ROLES=true
  3. Restart the bot
  4. Run /clone member_roles:True

Stuck somewhere?

The FAQ covers the errors people actually hit — missing commands, permission messages, roles landing in the wrong order.