Install pwa in smartphone with localhost

Viewed 8102

I have a pwa and with localhost I can install on desktop, but I can't with my samrtphone andorid. Is it possible install a pwa without upload in a http server?

UPDATE: I founded a work around that works, I putted a server on a port on my android smartphone using Dory - node.js (I have installed also express package)

https://play.google.com/store/apps/details?id=io.tempage.dorynode

Opening chrome in that port I see the "add to home screen popup".

1 Answers

This is unfortunately not an entire solution but an advice on where to look:

  1. Make sure you are in the same wifi network with your Desktop and your phone.
  2. Find out the local IP address of the Desktop PC (probably something like 192.168.0.x). You can find it under ipconfig (Windows) or ifconfig (Unix)
  3. Host your PWA with the http server (remember to use ssl)
  4. Try to access your hosted website from the phones browser, using the IP address and the port, probably something like 192.168.0.x:8080
  5. If you serve your web page through another port (ex. 3000) make sure you configure Port Forwarding through your Router default config IP address

You should be able to open the website. So far I was not able to call the install event, but I will update my answer if I find out more.

Related