I have developed a game, wanted to export it into Web GL. The error below keeps appearing before the page displays.
“It seems your browser does not support running Unity WebGL content from file:// urls. Please upload it to an http server, or try a different browser.”
What can I do to fix this issue?
ps: I’m new to Unity Build Settings.
How To Enable WebGL in Chrome
1-Open a Chrome browser window and go to chrome://settings.
2-Scroll down to Show Advanced settings at the bottom of the page.
3-Scroll to the System section. …
4-In your Chrome URL bar, go to chrome://flags.
Ensure that WebGL is enabled, and not disabled (You’ll need to relaunch Chrome for any changes to take effect
https://get.webgl.org/ - open this url in your browser, if you will see a spinning cube your browser supports webgl .
(your browser should be google chrome
“It seems your browser does not support running Unity WebGL content from file:// urls. Please upload it to an http server, or try a different browser.”
As you can see the Unity no longer support running a WebGL app from a file (like opening the generated .html in your browser)
You’ll need to start a local server that will host your app so you’ll be able to access it from a local url (like localhost:port or 127.0.0.1:port)
It doesn’t work on Github, but I tried on simmer.io. The game is working, but when I click on Play, the loading scene doesn’t seem working.
I am using C# for scripting. Will the script be affected? Anything that I should change as I can’t find any similar issues posted here?
ps: Please share me any link if you find a similar post.