Skip to content
Game servers

Valheim console commands: admin commands, cheats and your server

Published on 31 October 2026

Valheim console commands are typed into the console that you open in a world with F5. There are three kinds: player commands that anyone can use, admin commands such as kick and ban for players on adminlist.txt, and cheats, which only unlock after you type devcommands. According to the Valheim Wiki, cheats work in singleplayer and in a world you host from the game, not on a dedicated server. And since Valheim 1.0, most cheats lock your character and world out of achievements. Checked for Valheim 1.0.21, the patch of 28 October 2026.

Valheim console commands at a glance
KindWho can use themExamples
Player commandsEveryonehelp, ping, say
Admin commandsPlayers on adminlist.txt of a dedicated serverkick, ban, save
CheatsAfter devcommands, not on a dedicated servergod, fly, spawn

How do you open the console in Valheim?

On PC the console is off by default. Iron Gate explains how to turn it on:

  • Steam: right-click Valheim in your library, choose Properties and add -console under Launch Options.
  • Microsoft Store or PC Game Pass: add -console to the end of the Target field of a shortcut to Valheim.exe, after a space.
  • Xbox: the console is on by default.

Then press F5 in a world. On a controller, press LB, LT and Start together. Nothing happens on a laptop or Mac keyboard? Check that the function keys are not in Fn mode, and start the game through the same shortcut you added the option to.

Player commands anyone can use

Useful Valheim player commands, no cheats needed (Valheim Wiki)
CommandWhat it does
helpLists the commands
pingShows your latency to the server
say, sSends a chat message, or shouts it
lodbias 5Sets the draw distance, from 1 to 7
fov 80Changes your field of view
maxfps 60Sets a frame rate limit
printseedsPrints the seeds and positions of nearby dungeons
resetspawnResets your spawn point
clearClears the console window

Emotes work in the chat with a slash in front, such as /sit, /wave and /cheer.

Admin commands on a dedicated server

Players whose ID is on the server's adminlist.txt get a few extra commands. They type them in the game, in the console under F5:

  • kick with a name, IP address or ID: removes a player from the server.
  • ban and unban: bans a player, or lifts the ban.
  • banned: lists everyone who is banned.
  • save: saves the world straight away.
  • setworldpreset, setworldmodifier and resetworldkeys: change the world modifiers of the whole world, such as the difficulty, or reset them. See Valheim world modifiers on your server.

Being an admin gives you these commands only. It does not unlock cheats or debug mode on a dedicated server.

How do you make yourself admin on a Valheim server?

  1. Find your ID. Open the F2 panel in the game, or look in the server log while you connect: the ID of every player appears there. On our servers, that log is the console in the game panel.
  2. Copy it exactly. Iron Gate describes the form as platform, underscore and user ID, and it is case sensitive. A Steam ID looks like Steam_7656119XXXXXXXXXX.
  3. Add it to the list. In the game panel, open File managers, go to the saves folder and open adminlist.txt. Put each ID on its own line, with no spaces or comments.
  4. Restart and test. Restart your server and connect again. If banned does not work, check that your ID is exactly right.

bannedlist.txt works the same way for banned players, and permittedlist.txt is a whitelist. Be careful with that one: according to Iron Gate, adding a person to the permitted list bans everyone else. To keep strangers out, a good password and Public Server turned off in Startup are usually enough.

Your own Valheim world, online day and night? On a Valheim server from CakeHosting you decide who gets in, and your world keeps running while you sleep. See the Valheim server plans, from €4.95 a month.

Cheats: how devcommands works

Type devcommands in the console to turn cheats on, and type it again to turn them off. Then debugmode adds a few shortcut keys: B to build without a workbench or materials, Z to fly, K to kill nearby enemies and L to remove items lying on the ground.

The most useful Valheim cheats, as written on the Valheim Wiki
CheatWhat it does
godYour health never drops below 1
ghostEnemies ignore you
flyTurns flying on or off
healRefills health, stamina and eitr
spawn Wood 50Spawns 50 wood; also works for creatures, with a level as a third number
tod 0.5Sets the time to noon; 0 and 1 are midnight, tod -1 goes back to normal time
skiptimeSkips ahead, 240 seconds by default
sleepSkips forward one day
exploremapReveals the whole map; resetmap hides it again
killenemiesKills nearby enemies; killall also kills tamed creatures
tameTames nearby tameable creatures
raiseskill Swords 10Raises a skill; All raises every skill
posShows your coordinates; goto with x and z takes you there
eventStarts a raid by name; stopevent ends it

Go easy with spawn: thousands of items at once can make the game hang.

What do cheats do to your achievements?

Valheim has had achievements since 1.0, and Iron Gate protects them from cheats:

  • A lasting flag. Most devcommands, such as spawn, mark your character and the world save as permanently locked out of achievements. The photo camera freefly is the exception.
  • Cheated items. Spawned items are visibly marked as cheated. If a player without cheats picks one up, that character is in a temporary cheat state until the cheated items are gone again.
  • Mods count too. According to the Valheim Wiki, mods also block achievements. How to install them: Valheim mods.
  • Changed your mind? The Valheim Wiki lists the devcommand yesiuseddevcommandsbutiwantmyachievementsanyway, which turns achievements back on after you used devcommands.

What works on your dedicated server?

  • Everyone plays fair. Cheats such as god and fly do not work on a dedicated server, not even for admins. What admins do get: kick, ban, unban, save and the world modifiers.
  • Characters travel with the player. Your character is stored on your own PC, not on the server. Items spawned in singleplayer can therefore end up in your shared world.
  • Want to cheat in the server world anyway? Download the world, open it in the game itself and upload it again. The world then carries the cheat flag, so make a backup first.
  • Type save before a restart when you have just built a lot.

Friends on Xbox or PlayStation joining in? Read Valheim crossplay server. Still setting up? Start with How to set up a Valheim dedicated server.

Frequently asked questions

How do you open the console in Valheim?

On Steam, add -console to the launch options of Valheim; with the Microsoft Store version, add it to the Target field of a Valheim.exe shortcut. On Xbox the console is on by default. Then press F5 in a world, or LB, LT and Start together on a controller.

How do you turn on cheats in Valheim?

Type devcommands in the console. Cheats such as god, fly and spawn then work; type devcommands again to turn them off. Most cheats permanently lock your character and world out of achievements, so think before you spawn.

Do cheats work on a Valheim dedicated server?

No. According to the Valheim Wiki, cheats only work in singleplayer and in a world hosted from the game. On a dedicated server, admins get kick, ban, unban, banned, save and the world modifier commands.

How do I become admin on my Valheim server?

Find your ID in the F2 panel or in the server log while you connect, and put it on its own line in adminlist.txt in the saves folder. Copy the ID exactly, as it is case sensitive, then restart the server and connect again.

Can I still get achievements after using cheats in Valheim?

Normally not: most devcommands mark your character and world permanently. The Valheim Wiki lists a separate devcommand, yesiuseddevcommandsbutiwantmyachievementsanyway, that turns achievements back on.

More questions? See all frequently asked questions

Related articles