Skip to content

Team Fortress 2: Adding Bots

Learn how to add bots to your Team Fortress 2 game server and set their number and difficulty.

30 November 20262 min read0 Views0 helpful

Don't have your own server yet? Host your Team Fortress 2 server with ZAP-Hosting from €4.49 / month.Or try 3 days from €0.81

Introduction

Not enough players online? Bots can fill up your Team Fortress 2 game server so you can get a match going even during quiet hours, or test maps and settings without any other players. In this guide, we’ll show you how to add bots, control their number, and set their difficulty.

Adding bots while the server is running

In ZapX, open your server’s Console tab and enter the number of bots you want:

Code
tf_bot_quota 6

Use tf_bot_quota 0 to remove all bots. Values entered in the Console tab only apply until the next restart.

Setting up bots permanently

To make sure the bots return after every restart, add the commands to the custom.cfg file:

  1. In the Files tab, open the tf/cfg folder.
  2. Open the custom.cfg file. If it doesn’t exist yet, create it.
  3. For example, add these lines:
cfg
tf_bot_quota 6
tf_bot_quota_mode fill
tf_bot_difficulty 1
  1. Save the file and restart your server.

Server Configuration explains why your own settings belong in custom.cfg rather than server.cfg.

Bot commands at a glance

CommandMeaning
tf_bot_quota <anzahl>Target number of bots. 0 = no bots
tf_bot_quota_mode <modus>How the number of bots is managed: normal, fill, or match
tf_bot_difficulty <stufe>Bot difficulty: 0 easy, 1 normal, 2 hard, 3 expert

According to Valve, the tf_bot_quota_mode modes work as follows:

  • normal: The server always has the number of bots specified by tf_bot_quota.
  • fill: The server adds bots until the combined number of players and bots reaches the number specified by tf_bot_quota. When players join, bots leave.
  • match: The server maintains a fixed ratio of players to bots, with tf_bot_quota bots per player.
Tip

fill is a good choice for a community server that you don’t want to be empty during quiet hours. Bots take up player slots, so make sure tf_bot_quota is lower than Max. Players in the startup parameters.

Bots on custom maps

Bots need a navigation file (.nav) on the map with the same name as the map. For custom maps, upload it along with the .bsp file to the tf/maps folder, as described in Installing mods. Without a matching .nav file, your server can’t use bots on that map. If it’s missing, your server can generate it: switch to the map, then enter sv_cheats 1 followed by nav_generate in the Console tab. Depending on the map, this can take a few minutes; afterwards, the .nav file is in the tf/maps folder. Then reload the map, for example with changelevel and the map name, and set sv_cheats 0.

Conclusion

Bots can now fill your Team Fortress 2 server just the way you want. Find more useful commands in Server commands. If you have any questions, our support team is available every day! 🙂

Free tools

Team Fortress 2 Tools

View all

Feedback

Was this article helpful?

Your feedback helps us prioritize and improve content.

0 of 0 people found this article helpful.

Personal support

Need more help than the guide provides?

Our ZAP-Hosting support team knows your product — briefly describe your issue and we'll help you personally.

Zappy knows this guide and answers you right in the chat.