Run Ionic Serve With Custom Port

Sometimes it’s needed to test one single Ionic app or different Ionic apps in your browser, and ionic serve does now finally do a port check and use free ports:

The port 8203 was taken on the host localhost - using port 8205 instead

If you want to specify the ports themselves, you can pass additional option arguments when you run ionic serve like --port|-p for an specific webserver port. If you try ionic serve -p 8200 -i 35730, the app runs perfectly with the custom webserver and livereload port in your browser.

Here’s a list of the available arguments for ionic serve:


Share on FacebookShare on Google+Tweet about this on TwitterShare on LinkedIn