[UE5.0]How to enable console command in shipping build?

I tried to enable console command City Sample’s “shipping” build, but nothing to do with

-Add PublicDefinitions.Add(“ALLOW_CONSOLE_IN_SHIPPING=1”); in CitySample.Build.cs

Also cant select “test” build with this project. Anyway to enable console command?

1 Like

Console commands in Shipping build… I always thought it wasn’t possible in UE4/5.
But in a similar related thread recently apparently it is, so maybe @jwatte knows?

I think you’ll find console commands work in a UE5 shipping build at the moment, unless you build with the launcher.


I Package for Windows and it just works. I didn’t do anything special. This is using 4.27.2.

You have to use engine build from source code via Github, not from the Epic launcher.

The engine from Epic launcher can not make “Test” Build Package.
“Test” Build could be made from an engine built from source code only.

And for logging in shipping build, what you did in the build configuration file is not enough.
In addition to that, you have to modify Build.h in source of engine, like this : How to log in shipping build (Win)?

1 Like

Thank you for info. I tried to build from source UE5 but City Sample project always requires convert process even UE5 build by VS2019 or 2022. And this causes so much long time for compiling and optimizing every files I opened so I gave up. Anyway thanks for helps.

1 Like

As a workaround you can use widget in shipping build. Pass your command through widget and then execute it inside by ExecuteConsoleCommand

1 Like