How to close npm local tunnel port?

700 Views Asked by At

I had opened my localhost to the internet for a webhook using npm local tunnel and done my job. Now I'm exposing my port unnecessarily, I could still access my port using the URL. Now I need to close the tunnel. What should I do?

Long time ago, I shut down node service and the port closed. But now I can't find npm or node in my service. I need a simple command to close the port i.e. unexpose my port.

Commands I used:

npm install localtunnel
lt --port=8080
1

There are 1 best solutions below

0
On

you can close your Localtunnel session with ^C (Ctrl + C).
When you refresh the url, you will get a 404. That way you can confirm that the tunnel has been terminated.