23.11.2022 |

Test how your Angular application works on a real mobile device during development

Both your development machine and your mobile device need to use the same Wi-Fi network.

  1. Start your application with --host --disable-host-check
ng serve --host --disable-host-check
  1. Check your local IP address (Linux, macOS)
ifconfig | sed -En 's/;s/.*inet (addr:)?(([0-9]*\.){3}[0-9]*).*/\2/p'

Example response: # this one is the important one
  1. Open your mobile device's web browser and open the website on <development-machine-ip-address:port>


Angular usually runs on port 4200. My Mac/Linux machine has the IP address
That's why I have to navigate to in my cellphone's web browser.

Zur Übersicht

Mehr vom DevSquad...

Adrian Görisch


Jan Sauer

PAW ist jetzt RapidAPI