Search code examples
javascriptandroidmobileprogressive-web-apps

Browse PWA in mobile


So I was exploring PWAs today and followed Your First Progressive Web App. It takes 5 mins and works on my laptop but the problem is, I can't figure out how to browse it through my phone yet. So I searched and found How can I access my localhost from my Android device? But unfortunately, the answers provided there don't work for me.

Why would that be? Does PWA require some different kind of setup? Am I going all wrong about this? Adiitionally I couldn't find any tutorials that take you to actually browsing your PWA in a mobile. Why?


Solution

  • While the Your First Progressive Web App tutorial tells you to start a server in your localhost. So as mentioned by @Anand, you won't be able to simply access the PWA in your phone.

    The most simple solution is to use ngrok. Using it will expose a public URL for your web app which you can access in any device you want.

    Simply install ngrok from here and follow through. Cheers ;)