Error Your browser does not allow to read local files.

Error
Your browser does not allow to read local files.

RMMZ
I goto File->Deployment...-> Select Redio button Web Browser/Android/IOS.
and Choot Exclued unused files and select ouput location and Click ok.

- I use this deployment folder Delopy to IIS, Browser with chorme browser Is show Gif Loop Load data.
- I Doble click index.html in folder open with chorme browser show text "Error Your browser does not allow to read local files."


Please help me
Thank you.
the error message tells you exactly what the problem is - and it has absolutely nothing to do with the RPG Maker.

You set your browser security settings to never open local files - which makes sense if all you're doing is surfing on the web, because no website should have access to your local files (that would be the sign of a malware or infected website).

However it causes problems when developing local HTML5-based games, because then you want to open the local files of your game (and from the game, you aren't on the web in that moment).

So basically you have to go to your browsers security settings and change them to allow local programs to access local files.
Please don't mess with your browser's security settings just to test your game out locally. Those settings (in firefox, anyway, not sure about the others) are restrictive when dealing with local files for good reasons. You really don't want potentially malicious code (not your game obviously, but other things like corrupted websites) to be able to read local files on your machine.

Instead, either deploy to a remote test server or get yourself a web server app. There's several free, lightweight ones floating around.
Me I use a command line tool called http-server.

You simply have to download NodeJS https://nodejs.org/ and then navigation to the folder of your web game in the command line. There you type "npx http-server" and open your browser at "localhost:8080" (or whatever address the command line shows you).

Hope it helps!
I was going to suggest Mongoose Web Server, but at the time of writing that, the download website was acting a bit weird (expired certificate, probably)
While @Aesica 's concern is well-founded, if you're only attempting to test your project then it should be no big concern. By the looks of things you're using google chrome, I recommend copying your browser shortcut on your desktop and adding some security flags into the location path,

Spoiler: Screenshot Guide
1604633045700.png

1604633128422.png

1604633220339.png

Add "--allow-file-access-from-files" to the end of target

Once you've followed those steps everytime you open that shortcut you're allowing access to your local files, so NEVER use that shortcut for web browsing only to test your project. Once you open that up you can simply drag the "index.html" to the browser and begin testing your game.

However, if you don't trust yourself to be able to simply not browse with that shortcut, just use a web server 🙂
Me I use a command line tool called http-server.

You simply have to download NodeJS https://nodejs.org/ and then navigation to the folder of your web game in the command line. There you type "npx http-server" and open your browser at "localhost:8080" (or whatever address the command line shows you).

Hope it helps!
I tried this method yesterday and it worked but now it doesn't. It says either "Failed to initialize graphics" or "Your browser does not allow to read local files." or opens to this weird white screen. Not sure what I did wrong.

@owokambo, please refrain from necro-posting in a thread. Necro-posting is posting in a thread that has not had posting activity in over 30 days. You can review our forum rules here. Thank you.


Please make a new thread instead.

Original thread: https://forums.rpgmakerweb.com/threads/error-your-browser-does-not-allow-to-read-local-files.129455/