Smart Systems for Home

Plain how-to guides for smart home, security and home Wi-Fi

7 Days to Die: Change Trader Hours on a Server

· 6 min read · Home Tech

In this article
  1. What You'll Need
  2. Step-by-Step
  3. Common Mistakes
  4. Tips
  5. Troubleshooting
  6. Frequently Asked Questions

This guide explains how to change the opening and closing times of traders on your own 7 Days to Die dedicated server. By default, traders operate from 06:00 to 22:00 in-game, but you can adjust these hours to create a more challenging or relaxed experience for your players. You'll need access to your server's configuration files, either through a hosting provider's control panel or directly on the machine running the server.

What You'll Need

  • Access to your server's file system (FTP, file manager in your hosting panel, or local folder if self-hosted).
  • A text editor like Notepad++ or VS Code (avoid plain Notepad on Windows, as it may not handle line endings correctly).
  • Basic familiarity with XML files.

Step-by-Step

  1. Stop the server. Before editing any configuration file, shut down your 7 Days to Die server to prevent changes from being overwritten or causing errors. Use your hosting panel's stop button or send the "shutdown" command in the console.
  2. Locate the server config folder. The file you need is called serverconfig.xml. It is usually found in the root directory of your server installation. For example, on a Linux server it might be at /home/7dtd/serverconfig.xml, and on Windows at C:\7DaysToDie\serverconfig.xml. If you use a hosting provider, check their file manager or documentation for the exact path.
  3. Open serverconfig.xml. Use your text editor to open the file. It contains many XML elements that control server settings.
  4. Find the trader settings. Look for the <property> lines that contain name="TraderTime" and name="TraderOpenTime". These are usually near the top of the file. If you don't see them, they may be commented out (lines starting with <!-- and ending with -->). If so, uncomment them by removing those markers.
  5. Edit the open time. The TraderOpenTime property sets the hour (in 24-hour format, 0-23) when traders open. For example, to make them open at 8 AM, set its value to 8. The line should look like:
    <property name="TraderOpenTime" value="8"/>
  6. Edit the close time. The TraderTime property sets the hour when traders close. For example, to close at 6 PM, set its value to 18. The line should look like:
    <property name="TraderTime" value="18"/>
  7. Save the file. Save your changes in the text editor. Ensure the file remains valid XML – no stray characters or unclosed tags.
  8. Restart the server. Start your server again. The new trader hours will take effect on the next in-game day. If you want to test immediately, you can use the console command settime 6 (or any hour) to advance time, but this will affect all players.

Common Mistakes

  • Editing the wrong file. Some server setups have multiple XML files. Make sure you're editing serverconfig.xml, not players.xml or a world-specific config.
  • Using 12-hour time. The values must be in 24-hour format. 6 PM is 18, not 6 (which would be 6 AM).
  • Forgetting to save before restart. If you restart the server without saving, your changes are lost.
  • Setting open time after close time. If you set open time to 18 and close time to 6, traders will be open from 18:00 to 06:00 the next day, which might not be what you intended. The game does not allow overnight hours unless you set open time higher than close time, which effectively makes them open overnight, but this can be confusing.
  • Editing while the server is running. Many server configurations are cached at startup. Editing while running may cause your changes to be overwritten when the server saves.

Tips

  • Backup first. Copy the original serverconfig.xml to a safe location before making changes. This makes it easy to revert if something goes wrong.
  • Use a schedule that fits your players. If your community is active in the evening, consider opening traders at 16:00 and closing at 02:00 (set close time to 2). This gives them a window after work or school.
  • Combine with other settings. You can also adjust DayLightLength to change how long a day lasts, which affects how quickly the trader hours pass. For example, a shorter day makes the trader window feel longer relative to the day cycle.
  • Test on a single-player game first. If you're unsure, create a local game, edit the same file in your local save folder, and test the hours before applying to your server.
  • Document your changes. Add a comment in the XML file (e.g., <!-- Trader open 8am-6pm -->) so you remember what you set.

Troubleshooting

Changes don't take effect. First, verify that you saved the file and restarted the server. If you're using a hosting panel, check if there's a separate "restart" button that also reloads configs. Some panels cache the file; try clearing the cache or using the "reload" option.

Server fails to start. This usually means your XML is malformed. Open the file and look for missing closing tags, extra characters, or uncommented lines. Compare with a backup if you have one. Common issues: using a non-ASCII quote, or leaving a comment unclosed.

Traders are always open or always closed. Check if you set open time equal to close time. If both are 10, traders will be open for only one hour (from 10:00 to 10:00? Actually, they'll be open from 10:00 to 10:00 the next day, which is 24 hours). To avoid confusion, keep a gap of at least 1 hour.

Players report trader hours are different from what you set. Make sure you edited the correct server's config. If you run multiple servers, each has its own config. Also, if you have a mod that overrides trader settings, that mod may take precedence.

Can't find the property lines. Some older versions of the game used different property names. If you don't see TraderOpenTime or TraderTime, search for Trader in the file. Alternatively, you can add the lines manually before the closing </config> tag, but ensure they are correctly formatted.

Frequently Asked Questions

Q: Can I set trader hours to be open 24/7?
A: Yes, set both TraderOpenTime and TraderTime to the same value, e.g., 0. This makes traders open all day, but note that this removes the risk of being caught outside at night, which some players may not like.

Q: Do trader hours affect all traders on the map?
A: Yes, the setting is global and applies to every trader (e.g., Rekt, Jen, Bob) in all worlds on that server.

Q: Can I set different hours for different traders?
A: No, the server config only allows one global setting. To have different hours per trader, you would need a mod that overrides individual trader NPCs.

Q: What happens if a player is inside a trader when it closes?
A: The player will be kicked out when the trader closes. They won't be trapped inside, but they may be outside at night, which is dangerous.

Q: Does changing trader hours affect the in-game clock?
A: No, it only changes when the trader NPCs are active. The day/night cycle remains unchanged.

Q: My server is from a hosting provider; can I still edit this?
A: Yes, most providers give you access to the server files via FTP or a file manager in their control panel. If you can't find it, contact their support.