Oblivion:Console

The console is an in-game tool available to PC players. From the console it is possible, while playing the game, to enter commands that will alter most aspects of gameplay, and it is also possible to obtain detailed information about NPCs, creatures, and other items in the game. The console is only available on a PC; there is no way to use the console on the Xbox 360 or PS3 platforms.

General Information
To enable the console, make sure the bAllowConsole is set to 1 in your oblivion.ini file. If it's not there, you can add it in the   section. The console can then be accessed in-game by toggling the 'tilde key' (the actual key can be ~, º, ¬, |,^, \, §, etc.. depending on your keyboard layout), found near the "1" key on most keyboards. The console prompt will appear in the lower left-hand corner of your screen. You can scroll the console output using the "Page Up" and "Page Down" keys. The console is not case sensitive: entering any of "tdt" or "TDT" or "TdT" will toggle the debugging text.

Many commands are targeted: this means that you may use "player.command" to affect the player character, or RefID.command to affect the NPC, object, or area specified by RefID. The RefID has to be enclosed within quotes. e.g.  . You may also target an NPC or object in the console by clicking on them, and then run "command" to affect the NPC or object. When an NPC or object is targeted in this way, their name and hex code will be displayed at the top of the console. For example, to unlock a door, open the console, click on the door so it is the active object in the console (its name and RefID are shown at the top of the screen), then type  .

Commands which are abbreviated (for example: "tai") can also be run by using their full name; thus, "toggleai" is synonymous with "tai," and "getactorvalue" is synonymous with "getav." In most cases the long command is an obvious progression from the abbreviation. Also, most "setSomething" commands have a counterpart "getSomething," even if the counterpart isn't shown here.

Some commands require a formid. Most articles on objects provide the id or ids for those items, but items from mods will begin with "xx", a code that will not work in-game. Follow the tips on this page to find the correct id to use.

If you are writing a series of commands in a textfile, to be executed with console command "bat" (read commands in the next section) you can use the symbol ";" to indicate a comment, that will not be executed.

An example of bat-executable textfile:
 ;Alchemy script for ingredients to resist poison.
 player.additem 0003365C 1 ; Gives me 1 Alkanet Flower.
 player.additem 00033673 1 ; Gives me 1 Dreugh Wax.

Warning: Use console commands with caution! It is easily possible to mess up your game if you modify settings at the console. Even if short term the game functions normally, you may later discover that you have made it impossible to complete a quest and therefore you cannot proceed normally with game play; fixing that problem can then make new glitches pop up elsewhere. Create a permanent saved game before experimenting with the console. If you need to use the console to fix a glitch, try to use the least powerful command possible.

Note: If you are running Oblivion on Windows XP Media Center Edition or Windows Vista, and an infrared remote receiver is plugged in (note that many laptops have this built in), your console may not function properly. In order to restore its functionality, unplug the receiver for your Media Center Remote (or if it's built in use the device manager to disable or uninstall "ITECIR Infrared Receiver" from "Human Interface Devices"). This will allow you to use the console, as the receiver interferes with Oblivion's programming. Additionally, a built-in infrared receiver on laptops can cause the same issue and disabling it in the Device Manager has proven to fix the console function. Alternatively, a   has been created to circumvent this problem. You can also use   (requires OBSE and latest oblivion patch) to change the key or use   (requires OBSE) to open the console. Using either of these will avoid any difficulties that the Ring of Console may have saving the game while toggling menus.

Commands
How to Read the Command Table
When a command requires arguments, e.g.  additem     , the brackets <> indicate that   should be replaced with the appropriate ID, and   with the appropriate quantity. The brackets are not part of the syntax. So  additem      becomes  .


|

|}
|-
|     || Returns the current stage of the specified quest || This shows you the current quest stage. 10 generally indicates quest accepted, other than that, it's all quest dependent.
|-
|       || Sets the current stage of a quest || Quest stages can be found on each individual quest page. First, select the quest you want to change in your journal. Use the SQT command to see the quest id, then use the getstage command to see the stage. Usually you add or subtract 10 to change the stage, but there are exceptions.
|-
|   || Kills all creatures in a large radius || Kills all actors in the loaded area -- in an exterior, the 5x5 cells around the player; in an interior, the cell that the player is currently in.
|-
|       || Adds   points to an attribute || Attributes are subject to the same rules as skills in the entry below, except that you may use negative values.
|-
|       || Adds   points to the skill || Skill name to use is the name minus spaces, e.g.  . If you enter a value that would cause the skill to exceed 255 it will reset back to 0 and continue adding the remaining. Negative values will crash the game. This command was subject to a bug that was fixed in Oblivion 1.1.511. Using it on older versions will appear to end the ability of a skill to level up, but the skill will resume to level, once its internal level (the level it would be at without using the Console Command) has caught up with the level dictated by the Console Command. Abilities such as Vampirism alter the base value of the skill, and are subject to the 255 limit. WARNING: Do not use a negative  , as this will cause the game to crash.
|-
|   || Teleports you to your quest target || This sometimes results in you being stuck in a wall, stuck in cinematic mode (can't move etc.), or can mess up the current quest. Be prepared to toggle collision (tcl) or reload. For quests with multiple targets,  , with   being an integer variable will teleport you between specific targets - e.g.  .
|-
|     || Pick reference by ID || Select an existing copy of an object/creature/NPC using its reference FormID. All subsequent targeted commands will use this object as the target. This is the same as clicking on the object in the console, but can be used even if the object is invisible or in a different area.
|-
|   || Add all spells to player || Note that this adds ALL spells of Oblivion, including the spells that were used to test Oblivion, and spells added by activated mods. Without using modifications, there are more than 600 spells. This will make your spell menu load slowly, and it is hard to find certain spells with so many.
|-
|   || Exit game without using menus || Will quickly print the word "Bye" to the console before exiting.
|-
|     [1] || Save game || Saves the game using the name specified. Using the optional "1" will also save a text file (name.ess.txt) which contains information about the save file (see Save File Format for more information).
|-
|   || Save ini settings || Forces a save of the oblivion.ini file with current settings in the Options menu. Useful to save your settings if your game crashes when exiting (some custom mods cause this).
|-
|     to   || Set Global Variable || Sets a global variable to the given value. Use   to see the current value.
|-
|   || Selects Debugging Info || Selects what info   displays. See SetDebugText for more info.
|-
|     || Set Player Fame ||
|-
|     || Set Player Infamy ||
|-
|       || Set Quest Object || Changes the quest object status of the specified object. Setting   to "1" will turn an object into a quest object: setting it to "0" clears quest item status.
|-
|   || Changes your gender || Can be used on NPCs if player is in separate area from target NPC. After doing so, the game must be saved and reloaded or game may crash when player enters an area with affected NPCs. Game may still become unstable after doing so. If you use the command on an NPC in the same cell as you, the game will crash.

Only changes body clothes and some dialogue. Face will remain the same (sometimes with Argonians a color change in the face occurs). If the subject has unique dialog then when they talk nothing will be said, only the subtitles (if enabled) will show. If used on the player, they will become headless, but the voice and body will still change.
|-
|   to   || sets the speed of how fast time advances in-game || Default value is 30. Setting the value to 1 will make time advance at the same rate as the real world. Setting value to negative will reverse time, but will turn the clock to negative values if allowed to past midnight. To fix glitches related to negative time, use the console command   
Altering the value of timescale can cause bugs to occur during various quests (e.g., A Brush with Death, Where Spirits Have Lease). Resetting timescale to the default value of 30 fixes the bugs.
|-
|   &lt;var&gt; || Show Value of Global Variable || Use   to set a variable.
|-
|   || Allows you to change your birthsign || Using this command doesn't empty your spellbook like in Morrowind.
|-
|   || Change Class || WARNING: Using this menu will reset all of your skills to their default initial settings. If you want to save your current skills, you'll have to open the escape menu right before clicking the final "done" button, save the game through the console ( ) and then reload it ( ). After the reload your Classes will be changed like you wanted them to be and your skills will not be reset)
|-
|   || Enchanting window || This will pull up the Enchanting window.
|-
|   || Change Race/Appearance || New racial abilities, benefits and weaknesses do not seem to be awarded properly when you use this menu, although the old ones are removed. WARNING: Using this menu will reset all of your skills to their default initial settings. If you want to save your current skills, you'll have to open the escape menu right before clicking the final "done" button, save the game through the console ( ) and then reload it ( ). After the reload your race and appearance will be changed like you wanted them to be and your skills will not be reset. WARNING: Using this command while wearing bound items may crash the game.
|-
|   || Spellmaking window || This will pull up the Spell Making window.
|-
|   || Show all quests || List all quests in the game, not just ones you're on, along with current stage.
|-
|   || Show current quest || Shows the status of the current quest.
|-
|   || Creates a window with the full game scene graph || You may need to Alt-Tab out of Oblivion to see the window.
|-
|     || Set Weather || Allow the weather to, more gradually, morph into a particular type. See     for the codes.
|-
|   || Show Who's Detecting Player || Displays a list of characters currently detecting the player.
|-
|     || Get Game Setting || Returns the value of the referenced game setting. For example,   would return -10
|-
|       || Set Game Setting || Sets the referenced game setting to the selected value. For example,   would change the sneak bonus against sleeping NPCs to -40
|}

See Also
Console Command Tutorial
Understanding Formids
List of functions and console commands extracted from Oblivion.exe
List of functions added by the Oblivion Script Extender