[Open Source] soft-ue-cli — Control UE5 from the terminal or via MCP (60+ commands)

Hey everyone,

I’ve been building a tool called soft-ue-cli that lets you control Unreal Engine from outside the editor — either through a Python CLI or as an MCP server for AI editors.

How it works

The architecture is straightforward:

  • SoftUEBridge is a C++ plugin that inherits from UEngineSubsystem. It starts an HTTP server on port 8080 when UE launches.
  • soft-ue-cli is a Python CLI that sends JSON-RPC requests to that server.
  • All requests execute on the game thread via AsyncTask(ENamedThreads::GameThread, ...) to ensure thread safety with UE APIs.
  • Every command returns structured JSON to stdout.
Terminal / MCP Client
    |
    |  HTTP / JSON-RPC
    v
SoftUEBridge plugin (UEngineSubsystem, port 8080)
    |
    |  AsyncTask on GameThread
    v
UE5 native APIs

What you can do

60+ commands across these categories:

  • Actors — spawn, query, set properties, call BlueprintCallable functions, add components
  • Blueprints — inspect graphs, add/remove/connect nodes, compile, save
  • Materials — inspect parameters, nodes, connections, parent chains, Material Parameter Collections
  • StateTrees — query, add states/tasks/transitions
  • Widget Blueprints — inspect hierarchy, bindings, runtime widget geometry
  • PIE — start/stop/pause/resume, query actor state during play, send input events
  • Assets — create, delete, diff vs source control, find references, open in editor
  • Profiling — start/stop UE Insights traces, analyze CPU/GPU/memory hotspots
  • Screenshots — capture viewport, PIE window, or specific editor panels
  • Build — trigger Live Coding or full C++ rebuild with wait-for-completion
  • Python — execute scripts inside UE’s embedded Python interpreter

MCP server mode

Running soft-ue-cli mcp-serve starts an MCP server over stdio. It auto-generates tool schemas from the CLI’s argparse parser and exposes all commands as MCP tools. Compatible with Claude Desktop, Cursor, Windsurf, and other MCP clients.

pip install soft-ue-cli[mcp]

Setup

pip install soft-ue-cli

Copy SoftUEBridge into your project’s Plugins/ folder, add it to your .uproject, regenerate project files, rebuild.

For teams: you can conditionally compile the plugin using the SOFT_UE_BRIDGE=1 environment variable in your Target.cs, so only devs who need it get it compiled in.

Plugin details

  • Inherits from UEngineSubsystem (not UGameInstanceSubsystem) — starts with the engine, available before any world loads
  • Works in editor, Development, and Shipping builds
  • Writes .soft-ue-bridge/instance.json to your project root at startup for auto-discovery
  • Port configurable via SOFT_UE_BRIDGE_PORT env var
  • Single runtime dependency: httpx >= 0.27

Links

Happy to answer any questions about the implementation. The game thread dispatch and Blueprint graph editing were the most interesting problems to solve.