TShock Setup: Claim Owner Access and Create Your First Admin Account
A fresh TShock server has no admins. To claim it, you join the server, enter the one-time setup code TShock prints at first start, create a permanent account in the owner group, and log in. Do this as soon as the server first starts, before anyone else joins.
This guide walks through the steps and explains the older /auth method, which you may still see in older tutorials. It was checked on 2026-11-15 against two host guides that agree on the modern flow and one older tutorial for the legacy one. TShock itself is a separate project from Terraria, so make sure the TShock build you run supports your Terraria version. If you have not switched to TShock yet, ChicagoServers installs it in one click from the control panel, and our Terraria hosting page has the details.
- Start the server and read the Console tab. TShock prints a message like To setup the server, join the game and type /setup followed by a number.
- In game chat, run
/setup CODE, then/user add NAME PASSWORD owner, then/login NAME PASSWORD. - Older TShock versions used
/auth CODEand asuperadmingroup instead. Newer ones use/setupandowner. - The setup code is a one-time key to your whole server. Do not share it or leave setup unfinished on a public server.
- Players create their own accounts with
/register. Promote staff with/user group NAME GROUP.
On this page
Before you begin
- TShock must be running, not the plain Terraria server. If commands like
/setupdo not exist, you are on the vanilla server. - Your game version must match the server, and TShock has to support that Terraria version.
- You need to be able to join your own server, so check the address and port first. See the serverconfig guide if you are unsure.
- Join before other players find the server, or set a join password on the Startup tab first. The Join password field is described in the serverconfig guide.
Claim the server with /setup
- Start the server and find the code
Click Start, then open the Console tab. Look for the line telling you to join the game and type
/setupand a number. Host guides also say the code is saved in asetup-code.txtfile in TShock's folder, which you can open on the Files tab. The exact folder differs between hosts. - Join the server
Connect from Terraria as normal.
- Enter the code
Type this in the in-game chat. A success message means you now have temporary superadmin access.
/setup 1234567 - Create your permanent account
Choose a username and a strong password that you do not use anywhere else. The
ownergroup is the top group./user add YourName YourStrongPassword owner - Log in
Sign in with the account you just made.
/login YourName YourStrongPassword
The older /auth method
Older TShock versions, such as the 4.x line, used an authorization code instead of the setup command, and the top group was named superadmin. A host guide notes the owner group was called SuperAdmin before Terraria 1.4. If your server asks for /auth, the flow is:
- Authorise
Run the command with the code from the console.
/auth CODE - Create the admin account
The server asks you to make one in the superadmin group.
/user add YourName YourStrongPassword superadmin - Log in and verify
Log in, then verify. According to the older tutorial, the code stays active until it is disabled by
/auth-verify./login YourName YourStrongPassword /auth-verify
Add players and staff
| Command | What it does |
|---|---|
/register PASSWORD | A player creates their own account. |
/login NAME PASSWORD | A player signs in to their account. |
/user add NAME PASSWORD GROUP | Create an account in a group. |
/user group NAME GROUP | Change a user's group, for example to promote them. |
/group list | List the groups on your server. |
Run /group list to see the exact group names on your build before you promote anyone. Give staff the lowest group that lets them do their job, and keep owner for people you fully trust. Tuning behaviour such as logins and spawn protection is covered in the TShock config.json guide.
If it does not work
| Problem | Likely cause and fix |
|---|---|
/setup is not a command | You are on the vanilla server, or an older TShock that uses /auth. Check the console's message. |
| The code is rejected | Make sure you copied the code exactly. Read the latest one from the Console tab or setup-code.txt. |
| You cannot find the code | Scroll the console to the first start of the session, or open setup-code.txt on the Files tab. |
| You lose admin after a restart | Log in again with /login after you reconnect. The account is permanent, but you sign in to it each time you join. |
| Commands say you lack permission | You are not logged in, or your account is not in the owner group. Run /group list and check. |
| You forgot the password | Contact support if you cannot reach TShock's data files yourself. |
Moving an existing world onto the server is a separate job. See how to upload a Terraria world.
Frequently asked questions
How do I become admin on a TShock server?
Join the server, run /setup with the one-time code from the console, create an account with /user add NAME PASSWORD owner, and log in with /login NAME PASSWORD.
Where is the TShock setup code?
It is printed in the server console at first start, and host guides say it is also saved in a setup-code.txt file in TShock's folder.
What is the difference between /setup and /auth in TShock?
Newer TShock uses /setup and the owner group. Older versions used /auth and a superadmin group.
Why am I not admin after restarting my TShock server?
Your account is permanent but your login is not. Use /login NAME PASSWORD again after reconnecting.
How do players register on TShock?
They type /register PASSWORD in chat, then log in with /login. You can promote them with /user group NAME GROUP.