autoexec.cfg is for commands you have already tested and want to keep consistent. Do not put temporary crosshair experiments there, because every launch can overwrite later menu changes.
Use the correct folder
A common Windows Steam path is:
...\Steam\steamapps\common\Counter-Strike Global Offensive\game\csgo\cfg\autoexec.cfg
The important part is game\csgo\cfg. Also confirm that the real file name is not autoexec.cfg.txt.
Verify with a minimal file
Start with a current static-cross dimension example and an obvious console marker. Keep cl_crosshair_screen_height after dimension commands. This is not a complete preset; export the full current configuration from the generator to preserve color and other settings:
cl_crosshairstyle 4; cl_crosshair_length 8; cl_crosshair_gap 4; cl_crosshair_thickness 2; cl_crosshair_screen_height 720; echo "xhair autoexec loaded"
After launching, check the console for xhair autoexec loaded. You can also verify that CS2 can find the file manually:
exec autoexec.cfg
If manual execution works but startup loading does not, inspect execution order and launch options. +exec autoexec.cfg can make the execution explicit, but it should not hide an incorrect file path.
+exec autoexec.cfg
Keep old cfg files as historical backups. Previous-generation cl_crosshairsize, cl_crosshairgap, and cl_crosshairthickness are not current dimension commands, and their numerical values cannot simply be reused. Opacity now uses cl_crosshaircolor_a. Historical v1 originals remain unchanged and may be rejected by the current client. Only legacy static style 4 supports conversion: click Copy beside the crosshair, select your game resolution in the dialog, review the previews and warnings, then copy the compatible code. Use supported current v3 codes for import and editing; unsupported codes keep their originals without an assumed preview. A recent record or a CSGO- prefix alone does not establish compatibility.
Keep the config debuggable
- Include only settings you changed and understand.
- Give each crosshair variable one source of truth.
- Keep share codes as external backups; cfg files store commands.
- Back up the old file before editing.
When loading fails, check the extension, game\csgo\cfg path, console errors, marker output, and whether another cfg or startup command overwrites the same variables later.