Skip to content
/SLASHPLAY

How to force a direct connection in CS2

Type net_client_steamdatagram_enable_override -1 in your game console to prefer a direct connection over Valve's relay; 1 prefers the relay.

net_client_steamdatagram_enable_override

Forces how you connect to servers: through Valve's relay network, directly, or the matchmaking default.

net_client_steamdatagram_enable_override <-1|0|1>

Examples

net_client_steamdatagram_enable_override 1

Prefer the relay network.

Values

ValueWhat it does
-1 Prefer direct UDP
0Default Default, as matchmaking requests
1 Prefer Steam Datagram Relay

Arguments

modeRequired
Negative for direct UDP, 0 default, positive for relay.

What it does

Overrides whether your connection goes through the Steam Datagram Relay network or straight to the server. A positive value prefers the relay, a negative value prefers direct UDP, and 0 follows what matchmaking asks for.

The game's own description: 0: Use connect method requested by GC. >0: Always use SDR if possible. <0: Always use direct UDP if possible

Use it in your game

Type it in your own game console: turn on the developer console in the game's settings, then press the key under Esc. To keep it, put the line in game/csgo/cfg/autoexec.cfg.

Your own
CS2 server.

From $0.03 an hour, only while it runs. New accounts get 6 free tokens.