Fixes to play HTML5 builds on

.HTML file produced by the HTML5 build process doesn’t works when published on The fixes are simple:

  • as content is distributed via HTTPS, replace http:// occurences with https:// (they are used to download common files from CDNs - in the line 7,8 and 9) [maybe also the argument in -filehostIp= near line 205?].

  • to fix the loose of keyboard inputs (I think due iframe embedding), immediately below <script …> (line 126) add the following 2 instructions to force the focus to the game window:

    window.onload = function () { window.focus(); }
    window.onclick = function () { window.focus(); }

See also Upload HTML5 game to - Platform & Builds - Unreal Engine Forums

Hey Kafu,

I have tested this on and have entered report UE-29886. Once our Developers have reviewed the issue, I will provide you updates with any fixes or suggestions provided.

Thank you!

Hi , thanks for the follow-up! I saw the post was not complete (maybe some formatting character cropped the original text). I think to have fixed it, completing the instructions for the second fix too.


Could you please explain what you’ve changed in order to get it to work? I have entered the bug and the developers are looking into why it wasn’t working with what you had provided to us.

Thanks! :slight_smile:

Hi , sure. Attached you find the patch file with the reported fixes.[link text][1]

88629-html5.patch.txt (1.09 KB)


When you upload your project as a zip file, it’ll load without any trouble. Do not try to use winrar as it does not work the same as zipping does. UE-29886 has been closed out.


Hi , I don’t understand your comment: I never used WinRar, always uploaded ordinary Zip files, without the patch the release build don’t work on (it uploads correctly on, but it can’t run correctly).

Can you please explain how it’s not running correctly? We uploaded zip files ourselves and never ran into any trouble. The only time we ran into trouble was uploading without a zip and also using rar to zip the project up with.

What files are you including in your zip?