Ingo Steinke is a web developer focusing on front-end web development to create and improve websites and make the web more accessible, sustainable, and user-friendly.
If you only need to access you localhost server from other devices for cross-device testing, you don't need a shared internet connection at all. You can open a hotspot on the device running the server and connect the other devices to that specific hotspot network.
In most operating systems, there is a built-in hotspot option in the network settings, and opening a hotspot will temporarily break the connection to your wifi router as a usual networking device can only manage one wifi connection at the same time. This will also change your local IP address(es).
In my example, after opening a hotspot, inet 192.168.1.170 is gone, instead there is inet 10.42.0.1 which can be accessed by deviced connected to my computer. And this time it's also password protected by default. Nice! And if we need both the local connection and actual internet (and we're not on a train) we can use a cable connection (via Ethernet cable to the router or USB tethering with a phone connected to a mobile service provider).
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
If you only need to access you localhost server from other devices for cross-device testing, you don't need a shared internet connection at all. You can open a hotspot on the device running the server and connect the other devices to that specific hotspot network.
In most operating systems, there is a built-in hotspot option in the network settings, and opening a hotspot will temporarily break the connection to your wifi router as a usual networking device can only manage one wifi connection at the same time. This will also change your local IP address(es).
In my example, after opening a hotspot,
inet 192.168.1.170
is gone, instead there isinet 10.42.0.1
which can be accessed by deviced connected to my computer. And this time it's also password protected by default. Nice! And if we need both the local connection and actual internet (and we're not on a train) we can use a cable connection (via Ethernet cable to the router or USB tethering with a phone connected to a mobile service provider).