NEW 📢 Limited launch offer: up to 70% off your first month on every game!See plans

How to kick, ban and unban players on your Counter-Strike 1.6 server

Counter-Strike 1.6Updated Oct 30, 20264 min read

To kick or ban a player on a Counter-Strike 1.6 server on PlayNHost, type amx_kick or amx_ban with their name in the Console tab of the panel. A ban of 0 minutes is permanent. To lift a ban, type amx_unban with their SteamID. AMX Mod X admins can type the same commands in the game console.

Ban a player

  1. Open your server in the panel and click the Console tab.
  2. Type status and press Enter. The list shows each player's name, userid and uniqueid, which is their SteamID.
  3. Type amx_ban "PlayerName" 0 "cheating" and press Enter: the name, the minutes (0 is permanent) and a reason.
  4. The player is kicked with the reason. The Console prints Writing banned.cfg. as the ban list is saved.

When two names look alike, use the number from the userid column with a # in front instead of the name, for example amx_ban #12 60 "spam". That bans player 12 for 60 minutes.

Which command does what?

CommandWhat it does
amx_kick "name" "reason"Kicks the player. They can join again.
amx_ban "name" <minutes> "reason"Kicks and bans their SteamID.
amx_banip "name" <minutes> "reason"Kicks and bans their IP address.
amx_addban "STEAM_0:0:123456" <minutes> "reason"Bans a SteamID or IP address of a player who is not online.
amx_lastLists the last few players who left, with their SteamID and IP address.
amx_unban "STEAM_0:0:123456"Lifts a SteamID ban. Use an IP address to lift an IP ban.
amx_slay "name"Kills the player in the round.
amx_slap "name" <power>Slaps the player, with damage if you give a power.
amx_whoLists the players and their admin rights.

These come from the AMX Mod X admin plugin that is installed and running on every new server. In the game, admins also find kick and ban in the menu that amxmodmenu opens.

How do I unban a player?

  1. Find their SteamID. It is in cstrike/banned.cfg in Files, on a line that starts with banid. For a player who left a moment ago, amx_last in the Console tab shows it.
  2. Type amx_unban "STEAM_0:0:123456" with their SteamID and press Enter.
  3. For an IP ban, type amx_unban 203.0.113.5 with their IP address. IP bans are in cstrike/listip.cfg.

The player can join again at once.

The file editor with cstrike/banned.cfg open, showing a banid line with a SteamID

Where are bans kept, and do they survive a restart?

  • Permanent bans (0 minutes) are written to cstrike/banned.cfg (SteamIDs) and cstrike/listip.cfg (IP addresses). They load when the server starts through the lines exec banned.cfg and exec listip.cfg in cstrike/server.cfg. Open that file in Files and add the two lines if they are not there.
  • Timed bans are kept in memory only. A restart ends them early.

Backups include both files: How to back up and restore your Counter-Strike 1.6 server.

Who can kick and ban?

The panel's Console tab can always. In the game, an admin needs the access flag c to kick and d to ban and unban; v allows timed bans only. An admin with the flag a cannot be kicked or banned by other admins. To give these rights, see How to become admin on your Counter-Strike 1.6 server.

A banned player sees You have been banned from this server when they try to join. Other join messages are in Counter-Strike 1.6 server problems and fixes.

Already hosting it somewhere else? Move your server to us

OUR LATEST BLOGS