⚠️
Port forwarding may face security risks and are best recommended only for ad-hoc testing and development.
Visual Studio Code has a built-in support for port forwarding via Microsoft Dev Tunnels (does not require downloading extensions), which can make the service accessible to other people over the internet. By default, tunnels are private and only accessible to the creator (requires sign-in with the associated Github account), but can be changed to public.
Using Port Forwarding
- Run a service in the local machine
- Navigate to the Ports view in the Panel
- Select Forward a Port, and enter the port (i.e. 3000)
- Wait for port forwarding system to start and the Ports view will show the forwarded address
ℹ️
Sign in to Github is required if you have not logged in