Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by Mchia_soo · Aug 10, 2020 at 09:28 AM · unity 5webgl

Browser doesn't support Web GL

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.

Comment
Add comment · Show 2
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Mchia_soo · Sep 07, 2020 at 04:54 AM 0
Share

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.

avatar image BRX99_GS · Sep 08, 2020 at 01:37 PM 0
Share

$$anonymous$$aybe the problem in your game or in the scene , whyn't to try to upload it to paco games ? and take a look here it may help you: https://forum.unity.com/threads/webgl-player-loads-and-then-nothing-local.327348/ --- & here: https://www.youtube.com/watch?v=$$anonymous$$di-5I8fD$$anonymous$$0 - - Good luck:).

2 Replies

· Add your reply
  • Sort: 
avatar image
1

Answer by BRX99_GS · Aug 10, 2020 at 09:37 AM

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

Comment
Add comment · Show 3 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Mchia_soo · Aug 10, 2020 at 09:46 AM 0
Share

Thanks for your reply. I have tried on it, I see the spinning cube. Any other reasons that might cause this issue to happen?

avatar image Bunny83 Mchia_soo · Aug 10, 2020 at 11:09 AM 0
Share

This is a security restriction of the browser itself. While loading content from an actual http / https server is considered relatively "safe", loading content from the local file system implies all sorts of security concerns. First there's no domain name to restrict the access to. So a website loaded from the file system could essentially "scan" though your whole file system. Even when the browser restricts the access to the folder and subfolders of the first loaded html file, direct file access is a huge security concern. That's why you have to actively disable this feature in chrome with a command line parameter, see this article.


If you use FireFox (like I do), there's the option privacy.file_unique_origin in about:config which you can set to false which should do the trick. If not there'S also security.fileuri.strict_origin_policy which can also be disabled. For more information see this and this


In both cases you should be aware of the security risk. Whenever you open an html file locally from your file system, the content in that file has access to other files in your filesystem. So be aware what files you open locally.

avatar image BRX99_GS Mchia_soo · Aug 10, 2020 at 02:59 PM 0
Share

try to update your chrome,but if you use firefox look here maybe it will help you - https://www.reddit.com/r/Unity3D/comments/chrazu/solved_firefox_browser_does_not_support_running/

avatar image
0

Answer by Getsumi3 · Aug 14, 2020 at 09:00 AM

"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)

Comment
Add comment · Show 3 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Bunny83 · Aug 14, 2020 at 09:56 AM 0
Share

As mentioned above this has nothing to do with Unity but with the security restrictions of the browser. There are usually ways to circumvent those restrictions but of course hosting it on a server is usually the easiest solution. All this is stated pretty clearly in the error message itself.

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

Apart from that if you have a github account you can use github pages to upload your build and directly run it from github. I have several examples on github such as my parallel mandelbrot renderer. a Utah teapot renderer or my expression parser

avatar image Mchia_soo Bunny83 · Aug 25, 2020 at 07:53 AM 0
Share

Thanks for the comments. I will try uploading on GitHub. Hopefully everything runs well.

avatar image Mchia_soo Bunny83 · Sep 07, 2020 at 06:30 AM 0
Share

@Bunny83 I'm wondering, if you change your code from C# to javascript before exporting the game into WebGL?

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

237 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Unity 4 compatibility to Unity 5 WebGL 1 Answer

Unity 5.6 Webgl Photon Spawn Error 0 Answers

How to make elements added on runtime responsive in a vertical layout group in unity webgl? 0 Answers

Unity5 WebGL gyroscope access 2 Answers

What to use instead of movie texture in Unity 5 webGL? Is there any workaround? 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges