The Windows edition of Terraria includes a dedicated server program named TerrariaServer.exe. Open it from the game’s installation folder, choose or create a world, and leave its console running while players connect. For repeatable starts, place the world, port and access settings in serverconfig.txt and launch it with TerrariaServer.exe -config serverconfig.txt.
Playing with friends? Godlike.Host runs hosted Terraria servers from 10 data-center locations, with free DDoS protection.
This guide covers the first launch, configuration files, world backups, LAN and internet access, router and firewall setup, administration commands, multiple server instances and the fixes for the connection problems that occur most often.
| # | Preview | Product | Price | |
|---|---|---|---|---|
| 1 |
|
505 Games Terraria 71501866 | $17.37 | Buy on Amazon |
| 2 |
|
Terraria Boss Rush: Hardmode Edition T-Shirt | $19.99 | Buy on Amazon |
| 3 |
|
Terraria Bunny Plush | $17.78 | Buy on Amazon |
| 4 |
|
Terraria PS Vita Game | $40.99 | Buy on Amazon |
| 5 |
|
CyberPowerPC Gamer Xtreme VR Gaming PC, Intel Core i5-13400F 2.5GHz, GeForce RTX 5060 8GB, 16GB... | $1,285.00 | Buy on Amazon |
As an Amazon Associate I earn from qualifying purchases.
What TerrariaServer.exe is and what you need
TerrariaServer.exe is the dedicated server executable supplied with Windows installations of Terraria. It runs without opening the normal game client. The server process loads a world, listens for player connections and keeps the world active while its console window remains open.
You need a Windows computer with the game’s server files, a world (or permission to create one), and an account with permission to open a local firewall rule. Decide first whether players will connect only from your home network or from the internet:
#1 Best Overall
- In Terraria, every world is unique-from the floating islands in the sky to the deepest level of The Underworld. Adventure to the ends of the earth, and defeat villainous bosses along the way. The world is your canvas!
- LAN: players use the host computer’s private address. No public exposure or router port-forwarding is needed.
- Internet: the router must pass the server’s TCP port to the host computer, and the operating-system firewall must allow the executable.
The server has no published universal player-count figure in the official reference. Set maxplayers to the value appropriate for your group and test the host computer and connection before inviting everyone.
Find TerrariaServer.exe
Steam installation
- Open Steam and select Terraria in your library.
- Open the game’s context menu and choose Manage → Browse local files.
- In the folder that opens, locate
TerrariaServer.exe.
Windows installations normally include this file. If it is not present, verify the game installation from Steam, then use Manage → Browse local files again. Do not launch a similarly named client shortcut; the dedicated server is the executable whose name ends in Server.exe.
Recommended Free Tools
Keep the server files easy to manage
You can run the executable in its original installation directory. A nearby subfolder for configuration and backups can make administration clearer, but remember that relative paths in a configuration file are resolved from the folder containing TerrariaServer.exe. If you move only the configuration file, account for that path rule when specifying a world.
Start a server interactively
Interactive mode is the fastest way to confirm that the executable works and to see the available worlds.
- Double-click
TerrariaServer.exe. - When the console lists existing worlds, enter the number for the world you want to load.
- If no suitable world exists, choose the creation option and follow the prompts for world size, difficulty, name and seed.
- Confirm the port and other prompts. Unless you deliberately choose another port, use the documented default TCP port,
7777. - Wait for the console to report that the server is ready, then leave this window open.
The console is the running server. Closing it, signing out the host or allowing the computer to sleep stops or interrupts the session. Players can join only while the process is running and the selected world is loaded.
Use serverconfig.txt for repeatable startup
A configuration file removes the need to answer the same prompts every time. Create a plain-text file named serverconfig.txt in the executable’s folder (or use an explicitly quoted path) and put one setting on each line in name=value form.
| Setting | Purpose | Values or example |
|---|---|---|
world |
Loads a specific existing world file. | world=C:Users<User>DocumentsMy GamesTerrariaWorldsMyWorld.wld |
autocreate |
Creates a world automatically instead of selecting an existing file. | 1, 2 or 3 |
seed |
Sets the seed used when a world is created. | seed=842193 |
worldname |
Names a world created by the server. | worldname=WeekendWorld |
difficulty |
Selects the world difficulty value. | 0, 1, 2 or 3 |
maxplayers |
Sets the intended simultaneous-player limit for that instance. | maxplayers=8 |
port |
Sets the TCP listening port. | port=7777 |
password |
Requires a password when players connect. | password=choose-a-long-password |
motd |
Displays a message of the day to connecting players. | motd=Be respectful and save before leaving |
Use either world= for a known .wld file or the creation settings such as autocreate, seed and worldname. Do not rely on both approaches to describe different worlds: an explicit world path makes the intended save unambiguous.
Rank #2
- Gaming Boss Battles design. Boss Rush: Hardfashion Edition items are perfect for fans of Terraria or anyone who likes cool video game clothes! These Terraria items feature the hardmode bosses and is a great way to show your enthusiasm for Terraria!
- Part of the official Terraria merchandise line from Re-Logic, the creators of Terraria! If you are a terraria fan or should know one, get this design to give yourself or others who play terraria a great gift.
- Lightweight, Classic fit, Double-needle sleeve and bottom hem
Example configuration
world=C:UsersAlexDocumentsMy GamesTerrariaWorldsWeekendWorld.wld
maxplayers=8
port=7777
password=replace-this-password
motd=Welcome - save before you exit
Replace the user name, world name and password. In a Windows text editor, make sure the file is really named serverconfig.txt, not serverconfig.txt.txt. If the path contains spaces, keep the path correctly quoted when you place it on a command line; the configuration file itself should contain the setting in the format accepted by the server.
Launch the configuration from Command Prompt
Open Command Prompt in the folder containing the executable, then run:
TerrariaServer.exe -config serverconfig.txt
The space before -config is required. The argument after it is the configuration filename or path. A quoted path is necessary when a folder name contains spaces:
Outdated Drivers Are Slowing You Down
One free scan finds every outdated or missing driver and matches the right update for your exact hardware.Free scan · exact hardware matchWindows Errors? Fix Them Before They Spread
Repair common Windows errors and clear accumulated junk for a smoother, more stable PC - no reinstall needed.Free scan · no reinstall"C:GamesTerrariaTerrariaServer.exe" -config "C:GamesTerrariaConfigsfriends server.txt"
For one-click startup, create a desktop shortcut whose target contains that same command, or save it as a batch file in the server directory:
@echo off
TerrariaServer.exe -config serverconfig.txt
pause
pause keeps the window visible if the process exits immediately, so you can read an error. Start the batch file again only after correcting the reported setting or path.
World files, save location and backups
On Windows, the setup guide places world files by default under:
C:Users<User>DocumentsMy GamesTerrariaWorlds
The angle-bracketed text is a placeholder for the Windows account name; the actual folder uses that account’s name. A configured world= line can point directly to a .wld file in this directory or elsewhere.
Rank #3
- Product Type:Toy Figure
- Item Package Dimension:11.6 cm L X 14.4 cm W X 15.8 cm H
- Item Package Weight:0.1 kg
- Country Of Origin: China
Back up safely
- Use the server console’s
savecommand before making a backup. - Stop the server with
exitso no writes are in progress. - Copy the selected
.wldfile to a dated backup folder or another drive. - Keep a copy of the matching
serverconfig.txtbeside the backup. It records the world path, port and access settings needed to reproduce the instance.
Do not replace a live world file while the server is running. If you need to restore one, stop the process first, copy the backup into the expected Worlds location, verify the world= path and then start the server.
Let friends connect over a home network
For a LAN-only game, find the host computer’s private IPv4 address and give players that address together with the port configured in the server. If you left the setting unchanged, that port is 7777. Players enter the address and port in Terraria’s multiplayer join flow.
- Keep the host computer powered on and awake.
- Leave the server console open and the intended world loaded.
- Ensure every player is on a compatible Terraria version.
- Use the host’s private address, not its public internet address, for devices on the same router.
Because LAN traffic stays inside the local network, you do not need to expose the port on the router. You may still need to allow the server through the host operating system’s firewall.
Let friends connect over the internet
Internet access requires two separate network permissions: the Windows firewall must allow the server, and the home router must forward the server port to the computer running TerrariaServer.exe.
1. Allow the executable through Windows Firewall
- Open Windows Security → Firewall & network protection.
- Choose Allow an app through firewall and approve the administrator prompt.
- Add or enable
TerrariaServer.exefor the network profile you use. If Windows asks whether to allow private or public networks, choose only the profile that matches your network.
If your security software has its own firewall, create an equivalent allow rule there. A successful server start does not prove that inbound traffic is permitted.
2. Give the host a stable local address
Port forwarding points to a private address. If the router later gives the computer a different address, the rule can silently point at the wrong device. Reserve the host’s current address in the router’s DHCP settings when that feature is available, or otherwise ensure the local address remains consistent.
3. Create the router port-forwarding rule
- Sign in to the router’s administration page.
- Open its Port Forwarding, NAT or similarly named section.
- Create a rule for TCP, using the exact port in
serverconfig.txt(TCP7777if unchanged). - Set the destination to the host computer’s private IP address and save the rule.
Forward only the port you actually use. If you change the server’s port value later, update the router rule and tell players the new port.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
Rank #4
- 14 Different environments (including dungeons, floating islands, jungles) that go to the extremities of the earth, up in the sky and all the way down to the very deepest depths of the world.
- Hundreds of weapons, armour and other items to craft, with character advancement.
- Explore to find different materials and make exotic potions, laser guns, magic wands, flamethrower, diving gear, speed boots, grappling hooks, chainsaws, magic mirrors, etc.
- 29 Different block types to build whatever you imagine!
- NPCs and a swarm of enemies (over 150 types) including goblins, wyverns, unicorns, and-GASP-clowns!
4. Give remote players the correct endpoint
Players outside your home network need the public IP address of the internet connection plus the configured port. Do not give them the private address used for LAN play. Test from a different network, such as a phone hotspot, because a test from inside the same router may be affected by the router’s handling of loopback connections.
When forwarding is not possible
Some connections use carrier-grade NAT, school or workplace restrictions, or a router you cannot administer. The official dedicated-server reference names Hamachi and Radmin VPN as alternatives; every player must install and join the same virtual network, and players then connect using the VPN-provided address. A managed server is another option when you cannot keep a host computer online, but it is separate from running TerrariaServer.exe yourself.
Run and administer the live console
Type commands directly into the server console and press Enter. The most useful commands documented for routine operation are:
| Command | Use |
|---|---|
help |
Displays available console commands. |
playing |
Lists players currently connected. |
save |
Writes the current world to disk before maintenance or backup. |
exit |
Saves and shuts down the server normally. |
exit-nosave |
Stops without saving; use only when you intentionally need to discard the current session’s changes. |
kick <player name> |
Disconnects the named player. |
ban <player name> |
Bans the named player. |
Player names containing spaces may require the exact syntax accepted by the running server; use help if a command is rejected. Save before planned restarts, then use exit instead of closing the console window.
Do these 3 things before closing this tab:
1Fix the driver behind crashes, sound loss and screen glitches2Clear out junk files and repair common Windows errors3Scan for outdated or missing drivers - takes under a minuteUseful startup switches
In addition to -config, the official reference documents these startup switches:
-secure-steam-lobby friends-lobby private-ip <ip address>-seed <seed>
Switches belong on the launch command, not as random lines in serverconfig.txt. For example:
TerrariaServer.exe -config serverconfig.txt -seed 842193
Use one source of truth for each setting. If a value is already fixed in the configuration, avoid adding a contradictory command-line value until you have confirmed which value the installed server gives precedence.
Best Value
- System: Intel Core i5-13400F 2.5GHz 10 Cores | Intel B760 Chipset | 16GB DDR5 | 1TB PCIe 4.0 NVMe SSD | Windows 11 Home
- Graphics: NVIDIA GeForce RTX 5060 8GB Graphics | 1x HDMI | 2x DisplayPort
- Connectivity: 1 x USB-C 3.2 | 2 x USB-A 3.2 | 6 x USB-A 2.0 | 1 x LAN | WiFi 6 | Bluetooth 5.3 | 7.1 Channel Audio
- Tempered Side Case Panel | Custom RGB Lighting | Keyboard and Mouse
- 1 Year Parts & Labor Warranty, Free Lifetime Tech Support
Run more than one Terraria server on one computer
Multiple instances are possible, but each process must have its own world, configuration file and listening port. The official setup guidance recommends a separate shortcut or batch file for every instance.
Free tools Windows power users keep installed
One-click scans. No signup required.
| Instance | Configuration | World | Port |
|---|---|---|---|
| Friends | friends-config.txt |
Friends.wld |
7777 |
| Build test | build-config.txt |
BuildTest.wld |
7778 |
The second port in this example is an alternative you choose; it is not the documented default. If the second instance is reachable from the internet, create a separate router forwarding rule for that port and allow it through the firewall. Never point two processes at the same world file at the same time.
Security and reliability practices
- Set a non-obvious
passwordbefore publishing a server address. - Share the public address and port only with the people who need them.
- Forward only the server port, not broad port ranges.
- Keep dated copies of the world and configuration before major building projects or software changes.
- Use the console’s
savecommand during long sessions andexitfor shutdown. - Prevent the host from sleeping while players are connected.
- Record each instance’s world path, port and batch file so a restart does not depend on memory.
Troubleshooting
The executable is missing
Use Steam’s Manage → Browse local files command and look in the folder that opens. Windows installations normally contain TerrariaServer.exe. If the game files are incomplete, verify the installation and check again.
The configuration is ignored
- Confirm the command has a space before
-config. - Check the filename and extension exactly; avoid an accidental
.txt.txt. - Use the path to the actual file, and quote it when it contains spaces.
- Remember that a relative path is resolved from the folder containing the executable.
- Start the command from the intended installation folder or use a fully qualified executable path.
Friends cannot join
- Confirm the server console is still running and the intended world finished loading.
- Verify that the player is using the same port shown in the configuration.
- Check the Windows firewall and any third-party firewall.
- For internet play, confirm that TCP port
7777(or your changed port) forwards to the current private IP address of the host. - Give remote players the public IP address; give LAN players the private address.
- If forwarding is impossible because of NAT or network policy, use a virtual-network alternative in which every player joins the same VPN.
The wrong world loads
Replace an ambiguous selection with an explicit world= line. Verify that the referenced .wld file exists in the expected Worlds directory and that the path is spelled correctly. If you recently restored a backup, stop the server before replacing the file and keep the configuration beside the restored world.
Several servers conflict
Give every process its own configuration file, world file and port. A duplicate port prevents one instance from listening, while a shared world risks competing writes. Update each shortcut or batch file so it points to the intended configuration.
Quick wins for a faster PC:
Clear out junk files and repair common Windows errorsFree Scan →Fix the driver behind crashes, sound loss and screen glitchesFind Drivers →Repair Windows errors before they cause bigger problemsFix Now →The server closes immediately
Run the command from Command Prompt or a batch file containing pause so the error remains visible. Check the executable path, configuration filename, world path and port value. Correct the first reported error, then start the process again rather than launching several copies at once.
Quick Recap
Quick launch checklist
- Locate
TerrariaServer.exewith Manage → Browse local files. - Start it once interactively and confirm that a world loads.
- Create and verify
serverconfig.txtwith a world, port, player limit, password and message. - Launch with
TerrariaServer.exe -config serverconfig.txt. - Allow the executable through the host firewall.
- For internet play, forward the configured TCP port to the host’s private IP.
- Give LAN players the private address or remote players the public address and port.
- Use
savebefore backups andexitfor normal shutdown.
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.




