Search code examples
ionic-frameworkionic2ionic3ionic-view

ionic serve with wifi hotspot to test on mobile


I'm trying to test our app in the mobile browser.

  • I started a wifi hotspot
  • Ran ionic serve on our project root
  • Connected to wifi on mobile device
  • On mobile browser went to http://localhost:8100

but I get a page not found. Shouldn't the ionic app load on browse if I connect to the wifi hotspot of the pc running the app server?


Solution

  • The best way to do it:

    1. Make Personal Hotspot from your mobile Device to your Computer
    2. run ionic serve
    3. Read the the output this command throws. There you can see an External IP-Adress
    4. Open the Browser on your smartphone and use the Exernal IP-Adress + 8100 (Port)

    For example: http://192.168.32.12:8100