Steam Online Subsystem not working in packaged build (UE5.6)

I’m testing multiplayer with the Steam Online Subsystem in Unreal Engine 5.6. Everything works fine inside the editor, but when I run the packaged build, it doesn’t connect to Steam.

In the logs I get these warnings:

LogSteamShared: Warning: SteamAPI failed to initialize, conditions not met.
LogOnline: Warning: STEAM: Steamworks: SteamUtils() failed!
LogOnline: STEAM: [AppId: 0] Client API initialized 0
LogOnline: OSS: Unable to create OnlineSubsystem instance STEAM

What I’ve tried:

  • Created steam_appid.txt with 480 inside.

  • Placed steam_api64.dll next to the EXE.

  • Running the build with the Steam client open.

Issue:
When I try to host a game, it seems to enter the map for a split second and then immediately kicks me back to the main menu.

I’m hitting the same issue and still haven’t found a solution. Here’s what I’ve also verified:

  • OnlineSubsystemSteam plugin is enabled in the Editor (Plugins).

  • It’s set to "Enabled": true in the .uproject file.

  • The modules are referenced in .Build.cs (OnlineSubsystem, OnlineSubsystemUtils, and OnlineSubsystemSteam as a dynamically loaded module).

  • Both players are set to the same Steam download region.

  • DefaultEngine.ini is configured like this:

[/Script/Engine.GameEngine]
!NetDriverDefinitions=Clear
+NetDriverDefinitions=(DefName="GameNetDriver", DriverClassName="/Script/OnlineSubsystemSteam.SteamNetDriver", DriverClassNameFallback="/Script/OnlineSubsystemUtils.IpNetDriver")

[OnlineSubsystem]
DefaultPlatformService=Steam
bUseBuildIdOverride=true
BuildIdOverride=1

[OnlineSubsystemSteam]
bEnabled=true
SteamDevAppId=480
SteamAppId=480
bInitServerOnClient=true
bAllowP2PPacketRelay=true
P2PConnectionTimeout=90

[/Script/OnlineSubsystemSteam.SteamNetDriver]
NetConnectionClassName="/Script/OnlineSubsystemSteam.SteamNetConnection"

[/Script/OnlineSubsystemUtils.IpNetDriver]
NetServerMaxTickRate=120

Despite all of this, the client often can’t find the session at all (Find Sessions returns 0 results). I’ve been stuck on this for a while and it’s getting frustrating, especially with how little clear documentation there is about getting OnlineSubsystemSteam up and running.

Has anyone found additional steps or common pitfalls we might be missing (particularly when using AppID 480/Spacewar)? Any pointers or diagnostics to enable would be greatly appreciated.

Hello there!

This conflict has showed around the community from time to time, usually with the same patterns (works in editor, fails in packaged build, sessions don’t show, or can’t be found).

The solution that found most sucess is to use the Steam Sockets plugin, in order to make sessions visible:

  • First, enable Steam Sockets
  • Then, in DefaultEngine.ini, swap the net driver:
[/Script/Engine.GameEngine]
+NetDriverDefinitions=(DefName="GameNetDriver", DriverClassName="SocketSubsystemSteamIP.SteamNetDriver", DriverClassNameFallback="OnlineSubsystemUtils.IpNetDriver")
  • Finally, replace instances of “SteamNetConnection” with “SteamSocketsNetDriver”
  • Remember to test in Dev packaged builds first

For further details regarding the scenario, please check the related thread below:

1 Like

Hey! For anyone running into this issue, I followed the steps by @brs-sebascova above. The result was that my listen server would kick me out of the session the second it loaded me into the map. After further investigating, brs-sebascova worked for me except the the “swap net driver block”. Instead add this:

[/Script/Engine.GameEngine]
!NetDriverDefinitions=ClearArray
+NetDriverDefinitions=(DefName=“GameNetDriver”,DriverClassName=“/Script/SteamSockets.SteamSocketsNetDriver”,DriverClassNameFallback=“OnlineSubsystemUtils.IpNetDriver”)

For some reason, my build needed the /Script/SteamSockets.SteamSocketsNetDriver.

Unreals official docs have you putting the Steam socket as both the Driver Class and the Fallback. I found that if you intend to fallback to NULL, then that implementation fails. Instead I used the OnlineSubsystem allowing the NULL connection to work as the backup.

1 Like