TShock is the most popular server modification for Terraria, adding permissions, user management, anti-cheat, and hundreds of commands. This guide covers installation and initial setup for your Terraria server.
What is TShock?
Tip
- Permission system - Control what each player/group can do
- User registration - Players can register accounts for persistent data
- Anti-cheat - Prevent hacked clients and item spawning
- Regions - Protect areas from building/destroying
- Warps - Set teleport points for players
- REST API - Remote administration and integration
Installing TShock
- 1Download the latest TShock release from github.com/Pryaxis/TShock
- 2Stop your Terraria server completely
- 3Extract the TShock files to your server directory
- 4The TShock files should be alongside your Terraria server files
- 5Start the server using TShock.Server.exe (Windows) or the appropriate executable
- 6On first run, TShock will generate its configuration files
- 7Check the console for the initial setup token
Tip
- Make sure to download the TShock version matching your Terraria version
- Backup your worlds before installing TShock
- The first player to join with the setup token becomes the superadmin
First-Time Setup
- 1When TShock first starts, it displays a setup code in the console
- 2Join your server and type: /setup <code>
- 3You'll be prompted to create a superadmin account
- 4Choose a strong password - this account has full control
- 5The setup process creates your superadmin user
- 6Type /login <password> to access admin commands
Tip
- Save your superadmin password securely
- The setup code is only shown once - note it immediately
- You can create additional admin accounts later
Permission Groups
/group listList all permission groups
Example: Shows default groups
/group addperm <group> <permission>Add a permission to a group
Example: /group addperm admin tshock.tp.self
/group delperm <group> <permission>Remove a permission from a group
Example: /group delperm default tshock.world.time
Tip
- Default groups: guest, default, newadmin, admin, trustedadmin, superadmin
- Players start in 'default' group when they register
- Use /user group <name> <group> to change a player's group
- Permission list: tshock.github.io/docs/permissions.html
Region Protection
/region define <name>Define a region from your current selection
Example: /region define spawn
/region set 1Set the first corner of a region
Example: Stand at corner and run command
/region set 2Set the second corner of a region
Example: Stand at opposite corner
/region protect <name> trueEnable protection on a region
Example: /region protect spawn true
/region allow <player> <region>Allow a player to build in a region
Example: /region allow Steve spawn
Tip
- Protected regions prevent block placement and destruction
- Admins with bypass permissions can still modify protected regions
- Use regions to protect spawn, shops, and important builds
Essential Configuration
"ServerPassword"Server-wide password for joining
Example: Leave empty for no password
"MaxSlots"Maximum player slots
Example: Default is 8
"RequireLogin"Require players to register and login
Example: true for private servers
"DisableBuild"Prevent building for guests
Example: true to require registration
"SpawnProtection"Protect spawn area automatically
Example: true recommended
"SpawnProtectionRadius"Spawn protection size in tiles
Example: Default is 10
Tip
- Always restart the server after editing config.json
- Use /reload for some config changes without restart
- Backup config.json before making changes
Ready to Start Your Terraria Server?
Get instant setup, powerful hardware, and 24/5 support with Loafhosts.
Get Terraria Hosting