Home / Docs / Gameserver / Terraria / Server Einstellungen

Terraria serverconfig.txt Explained

Every option in the Terraria serverconfig.txt explained: world, player count, password, port, difficulty and Journey permissions – with an example.

Quick answer: The Terraria server reads its settings from serverconfig.txt when it is started with -config serverconfig.txt. Each line has the form key=value; lines starting with # are switched off. Changes take effect after a restart.

Where is serverconfig.txt?

The file is usually in the server's main folder. Which file is used is shown in the start command after -config. On your rented server you find the start command in the panel under Startup and the file in the file manager or via SFTP.

If a value appears both in the start command and in the config, set it to the same value in both places – otherwise it is hard to tell which one applies.

Example config

world=/home/container/worlds/MyWorld.wld
autocreate=2
worldname=MyWorld
difficulty=0
maxplayers=8
port=7777
password=
motd=Welcome to our server!
worldpath=/home/container/worlds/
banlist=banlist.txt
secure=1
language=en-US

Adjust the folder in world and worldpath to your server.

World

  • world – full path to the .wld file to load. If set, the server starts straight into this world.
  • autocreate – creates a new world if none exists at world: 1 = small, 2 = medium, 3 = large.
  • worldname – name of the newly created world (only with autocreate).
  • seed – seed for the new world (only with autocreate).
  • difficulty – difficulty of the new world: 0 = Classic, 1 = Expert, 2 = Master, 3 = Journey. Only applies when creating a world; an existing world keeps its difficulty.
  • worldpath – folder that holds the worlds.

Players and access

  • maxplayers – maximum number of players, 1 to 255. Pick a value that fits your plan.
  • password – password to join. Empty = open.
  • motd – message of the day players see when joining.
  • banlist – file with banned players, default banlist.txt.
  • secure – 1 enables additional cheat protection.

Network

  • port – server port, default 7777. On a rented server the port is assigned – don't change it.
  • upnp – automatic port forwarding on a router. Not needed on a rented server.
  • npcstream – reduces enemy "skipping" at the cost of more bandwidth. Lower = less skipping, more data; 0 = off. The game's example config uses 60.

Other

  • language – language of server messages: en-US, de-DE, it-IT, fr-FR, es-ES, ru-RU, zh-Hans, pt-BR, pl-PL.
  • priority – process priority (0 = realtime to 5 = idle). Simply leave it out on a rented server.

Journey mode: setting permissions

In Journey worlds you decide per power who may use it: 0 = nobody, 1 = host only, 2 = everyone.

journeypermission_time_setfrozen=2
journeypermission_time_setdawn=2
journeypermission_time_setnoon=2
journeypermission_time_setdusk=2
journeypermission_time_setmidnight=2
journeypermission_godmode=2
journeypermission_wind_setstrength=2
journeypermission_rain_setstrength=2
journeypermission_time_setspeed=2
journeypermission_rain_setfrozen=2
journeypermission_wind_setfrozen=2
journeypermission_increaseplacementrange=2
journeypermission_setdifficulty=2
journeypermission_biomespread_setfrozen=2
journeypermission_setspawnrate=2

A dedicated server has no playing host. To lock a power for everyone, set it to 0.

Start parameters

You can use these parameters instead of (or in addition to) the config:

  • -config <file> – load a config file
  • -port <number>, -maxplayers <number>, -password <password>, -motd <text>
  • -world <path>, -autocreate <1|2|3>, -worldname <name>, -seed <seed>
  • -banlist <path>, -secure, -noupnp
  • -disableannouncementbox – disables announcement box messages

Important notes

  • Saving: the server only autosaves at dawn. Type save or exit in the console before stopping, or the last minutes may be lost. See Server commands.
  • Empty servers pause: no time passes on the server without players.
  • Mods: mods need tModLoader – see Installing mods.

Source: official Terraria wiki (terraria.wiki.gg: Server, Guide: Setting up a Terraria server) · Rent a server: Terraria server at NexoraHost

Need a server?

Order Gameserver, VPS or Root in Frankfurt.

To shop