The Photon Forum
is Closed Permanently.

After many dedicated years of service, we have made the decision to retire our Forum and switch to read-only: we´ve saved the best to last! Your search result can be found below. Plus, we offer support via these channels:

Try Our

Please check if you can find an answer in our extensive documentation on Fusion.

Join Us
on Discord

Meet and talk to our staff and the entire Photon-Community via Discord.

Stack Overflow

Find more information on Stack Overflow (for Circle members only).

Write Us
an E-Mail

Feel free to send your question directly to our developers.

Do Unity WebGL games always have to use the relay server?

2022-11-24 09:34:59


We're developing a fairly simple 2D game, almost entirely based on the Tankarok example project.

As we have to use WebGL, we're dealing with WebSockets overhead and high RTT, which we think is caused by the relay server. Incoming connections' NetAddress.IsRelayAddr is always true for WebGL builds but for standalone (.exe) is always false and the RTT difference is really noticeable - about 120ms for WebGL and 50ms for standalone builds.

All server instances (Unity headless builds) are hosted on PlayFab.

My question is - is using the relay server necessary for WebGL?



@EDIT: Okay I guess that the relay is needed because SSL is required for wss to work (obviously). So I think that the real question is - can we do anything to achieve lower RTT on WebGL?


Back to top