Skip to content
docs / headless-editor
Releases ← Back to site GitHub

Let the agent work without the editor window

You don’t have to keep Unreal Editor on screen for the agent to use it. Start the editor without a window and ClaudeUnreal’s bridge comes up exactly as usual: the agent edits the level, takes screenshots, plays the game and shuts the editor down, while you stay in your terminal.

Good for:

  • Agent-only sessions — “build this level, show me screenshots” — where you never need to click in the editor.
  • Machines that struggle with the full editor UI — no window, no viewport redraw while you work in other apps.
  • Scripts and long runs — start, work, verify, shut down, all from the command line.
Terminal window
"/Users/Shared/Epic Games/UE_5.8/Engine/Binaries/Mac/UnrealEditor.app/Contents/MacOS/UnrealEditor" \
"$PWD/MyGame.uproject" -RenderOffscreen -unattended -nosplash -nosound &
FlagWhy
-RenderOffscreenThe editor renders without opening a window. Screenshots still work.
-unattendedDialogs that would wait for a click are skipped, so nothing hangs waiting for you.
-nosplash -nosoundNo splash screen, no audio device.

The bridge is ready when the editor writes Saved/ClaudeUnreal/bridge.json in your project — usually well under a minute, longer on the first launch while shaders compile. Its port is 55557 unless another editor already holds that port. Then:

Terminal window
.claude/cu exec ping # Windows: .claude\cu.cmd exec ping

Paste this into Claude Code in your project folder:

Start Unreal Editor for this project without a window (-RenderOffscreen -unattended -nosplash -nosound, in the background), wait until Saved/ClaudeUnreal/bridge.json appears, then check it with `.claude/cu exec ping`. Use screenshots to show me your work as you go. When I say we're done, save what we changed and close the editor with `.claude/cu exec shutdown_editor`.

Checked on macOS with Unreal Engine 5.8:

TaskToolResult
Bridge checkping✅ pong
Read and edit the levelget_actors_in_level and the editing tools✅
Screenshot of the editor viewporttake_screenshot✅ full-resolution image
Play the game and capture itstart_play_in_editor, take_screenshot_pie✅
Close cleanlyshutdown_editor✅ exits in about 8 seconds and frees the port
  • Save before you close. shutdown_editor does not save by default — it discards unsaved changes so no save dialog can block the exit. Ask the agent to save first, or call shutdown_editor with save: true.
  • Several projects at once. Since ClaudeUnreal v0.7.2 every editor gets its own bridge: the first takes port 55557, the next ones a free port the OS assigns, recorded in each project’s Saved/ClaudeUnreal/bridge.json. cu and the MCP server read it, so each project’s agent talks to its own editor — and an agent that reaches the wrong one is refused instead of editing the wrong level. With v0.7.1 and earlier, keep to one editor per machine.
  • You can still look. Want to see the editor after all? Close the windowless one with shutdown_editor and open the project normally — everything the agent saved is there.
  • The MCP tools need the editor too. Claude Code’s claude-unreal MCP tools and the cu CLI both talk to the same bridge, so they work the same with or without a window.