Console Commands
List, inspect, and execute Unreal console commands and cvars. Unreal Engine 5 command reference with parameters and examples.
List, inspect, and execute Unreal console commands and cvars. Unreal Engine 5 command reference with parameters and examples.
9 commands. Each shows its parameters and an example, and has a copyable deep link, so you (or an AI agent) can jump straight to one.
list_console_commandsList engine + custom console commands and cvars (filterable)
Enumerates every console command and cvar registered with IConsoleManager, engine builtins, plugin commands, and any RegisterConsoleCommand call from game code show up identically. Filter is a case-insensitive substring (engine's ForEachConsoleObjectThatContains). Empty filter enumerates everything (~5000+ entries). Use this for discovery before guessing a command name. include_help adds the same help text the in-editor console autocomplete shows. include_values adds current cvar values via IConsoleVariable::GetString. type_filter narrows to commands or variables only.
| Parameter | Type | Required | Description |
|---|---|---|---|
| filter | string | No | Case-insensitive substring; empty = enumerate all |
| max_results | int | No | Cap on returned entries; 0 = unlimited |
| include_help | bool | No | Add help text per entry |
| include_values | bool | No | Add current value per cvar |
| type_filter | string | No | all | command | variable (anything else is refused) |
cfa list_console_commands --filter "pcg" --max-results 50 --include-help
cfa list_console_commands --filter "r.Screen" --include-values
cfa list_console_commands --filter "stat" --type-filter command --max-results 100get_console_command_infoFull metadata for one console command or cvar by exact name
Looks up a single console object via IConsoleManager::FindConsoleObject. Returns help text, type (command vs variable), ECVF_* flags set on it, and the current value for cvars. Use list_console_commands first to find the exact name if unsure, this call is exact-match only.
| Parameter | Type | Required | Description |
|---|---|---|---|
| name | string | Yes | Exact console object name |
cfa get_console_command_info --name "r.ScreenPercentage"
cfa get_console_command_info --name "DumpMassMemory"console_command_existsBoolean existence check (IConsoleManager registry only)
Single IConsoleManager::IsNameRegistered call against the ~10,000 cvars+commands registered with the IConsoleManager. IMPORTANT: this does NOT see engine FSelfRegisteringExec handlers, stat, show, Quit, Travel, Open, most Dump* and editor debug commands return exists=false here, but still execute fine through execute_console_command. The engine has no enumeration API for FExec handlers, so we cannot pre-check them. Practical rule: exists=true means it's safe; exists=false means try execute_console_command and trust exec_consumed as the truth signal.
| Parameter | Type | Required | Description |
|---|---|---|---|
| name | string | Yes | Exact console object name to test |
cfa console_command_exists --name "stat fps"
cfa console_command_exists --name "r.MyMadeUpCvar"execute_console_commandExecute any console command in the editor
Routes through GEngine->Exec with the active world (PIE if running, otherwise the editor world). Works for engine builtins, cvar sets, stat toggles, and any custom RegisterConsoleCommand handler. Set capture_logs=true for commands that report results via UE_LOG instead of writing to the output-device parameter, most stat/r./Mem/Show commands, RHI commands, scene-capture commands, and any custom command using UE_LOG. When capture_logs is on, FOutputDeviceRedirector::FlushThreadedLogs is called before detach so worker-thread logs reach the sink; a short warning is included noting other-thread log lines may appear in the window. Result fields: command_existed (IConsoleManager registry only, false for stat/show/Quit/etc.), exec_consumed (RELIABLE success signal, true if any handler took the command), handled_by_fexec_only (true when an FSelfRegisteringExec handler picked it up rather than IConsoleManager), ar_output (direct device writes), log_output (UE_LOG stream, only when capture_logs=true). COMMANDS WITH SIDE EFFECTS, confirmed from Engine/Private/UnrealEngine.cpp source: `help` writes Saved/ConsoleHelp.html AND launches it in the default browser via FPlatformProcess::LaunchURL on Windows (hardcoded #if WITH_EDITOR && PLATFORM_WINDOWS, no opt-out). Use list_console_commands instead, same data, zero side effects. `Quit`/`Exit` closes the editor. `Travel <map>`/`Open <map>` changes the loaded map. `RestartLevel` reloads PIE. `obj gc` forces GC. Safe alternatives to `help`: DumpCVars (cvars to log), DumpCCmds (commands to log), DumpConsoleCommands <prefix> (filtered to log), or the list_console_commands MCP tool (JSON, preferred).
| Parameter | Type | Required | Description |
|---|---|---|---|
| command | string | Yes | Full command string e.g. 'r.ScreenPercentage 80' |
| capture_logs | bool | No | Tee GLog into capture sink during exec (needed for UE_LOG-based output) |
| flush_threaded | bool | No | Flush threaded logs before detaching capture sink (only when capture_logs=true) |
cfa execute_console_command --command "stat fps" --capture-logs
cfa execute_console_command --command "r.ScreenPercentage 80"
cfa execute_console_command --command "DumpMassMemory" --capture-logs
cfa execute_console_command --command "show Collision"set_cvarSet a console variable with a type check, a read-back and a verdict
Sets a console variable the way typing it in the console does (console priority, the highest), then reads it back: the verdict fails when the variable clamps or rejects the value. A read-only variable is refused with where to set it instead (an ini file or the command line, then a restart); a console command is refused with execute_console_command; an unknown name lists close names. The value is checked against the variable's type (int, float, bool, string). The first value each variable had is remembered for this editor session, so reset_cvars puts it back.
| Parameter | Type | Required | Description |
|---|---|---|---|
| name | string | Yes | Console variable name, e.g. r.ScreenPercentage |
| value | string | Yes | New value: a number, true/false (or 1/0) for bools, any text for strings |
cfa set_cvar --name r.ScreenPercentage --value 50
cfa set_cvar --name t.MaxFPS --value 30
cfa set_cvar --name ShowFlag.Fog --value 0reset_cvarsPut back console variables that set_cvar changed
Sets each variable changed by set_cvar in this editor session back to the value it had before the first change, and reads it back with a verdict per variable. With no names it puts back every one.
| Parameter | Type | Required | Description |
|---|---|---|---|
| names | json | No | JSON array of variable names to put back (default: every variable set_cvar changed) |
cfa reset_cvars
cfa reset_cvars --names '["r.ScreenPercentage"]'read_output_logRead the output log, filtered by category, level and text
Reads the output log the editor keeps in memory: the newest 20,000 lines with their category and level, play sessions included. Filters: --category (part of the category name, e.g. LogAI), --verbosity (keep lines at this level or more severe: error, warning, display, log, verbose, veryverbose), --filter (text in the line), --since-seconds. The reply has the newest matching lines in time order as "<id> <seconds>s <Category> <Level>: <text>" (Log level is not written), how many matched, the error and warning counts, and last_id. To see only what a later action logs, pass that last_id back as --after-id.
| Parameter | Type | Required | Description |
|---|---|---|---|
| category | string | No | Only lines whose category contains this text, e.g. LogAI |
| verbosity | string | No | Only lines at this level or more severe: error, warning, display, log, verbose, veryverbose |
| filter | string | No | Only lines that contain this text (case ignored) |
| after_id | int | No | Only lines after this id (the last_id of an earlier read) |
| since_seconds | float | No | Only lines from the last N seconds (0 = no limit) |
| max_results | int | No | Most lines returned, the newest ones (at most 1000) |
cfa read_output_log --verbosity warning --max-results 20
cfa read_output_log --category LogAI --since-seconds 30
cfa read_output_log --after-id 18342list_log_categoriesList log categories and the level each logs at now
Lists the log categories the engine knows, engine and project, as "<name> <level>", from the engine's own log list command. Use it to find the category name for set_log_verbosity or read_output_log --category.
| Parameter | Type | Required | Description |
|---|---|---|---|
| filter | string | No | Only categories whose name contains this text |
| max_results | int | No | Most categories listed |
cfa list_log_categories --filter AI
cfa list_log_categories --filter Net --max-results 30set_log_verbositySet the level a log category logs at, with a read-back verdict
Sets a log category's level the way the log console command does (log <Category> <level>), then reads it back. Levels: none, error, warning, display, log, verbose, veryverbose, or default for the level it had when the editor started. A category compiled with a lower maximum level stays at that maximum and the verdict fails; on UE 5.7 and later the engine also logs an ensure for it. An unknown category lists close names. The change lasts until the editor closes.
| Parameter | Type | Required | Description |
|---|---|---|---|
| category | string | Yes | Log category, e.g. LogAI (list_log_categories lists them) |
| verbosity | string | Yes | none, error, warning, display, log, verbose, veryverbose, or default |
cfa set_log_verbosity --category LogAI --verbosity verbose
cfa set_log_verbosity --category LogNavigation --verbosity default