DEV Community

Cover image for ngrok - Expose Your LOCAL WEB Server to PUBLIC Internet (complete guide with Video) 📹

ngrok - Expose Your LOCAL WEB Server to PUBLIC Internet (complete guide with Video) 📹

Shahjada Talukdar on December 08, 2020

We, all the developers, sometimes in our life felt like - Okay, I have an app running in my localhost and I want to show this app to someone. If I ...
Collapse
 
crimsonmed profile image
Médéric Burlet •

From a security perspective I would not recommend that though. If you need to show it to someone better to make a docker container and run it on a free server on the web or share the container.

Collapse
 
destro_mas profile image
Shahjada Talukdar The Destro Dev Show • • Edited

I Fully agree from the Security Point of View.
If you compare this to a Real Cloud Server, then definitely the cloud one will take the slot.
This was created to LEARN/KNOW about a backup plan!
I also prefer a cloud server first.

Collapse
 
crimsonmed profile image
Médéric Burlet •

IMO this should never be done. You're exposing your filesystem to the Web and that's pretty if not very dangerous. Specially using a piece of software not following vest security practices.

There are many alternatives to webserver such as static hosting with s3 and more all free.

Thread Thread
 
destro_mas profile image
Shahjada Talukdar The Destro Dev Show •

Yeah, for sure.
I would also never use ngrok in any serious work.

Collapse
 
mirrorbytes profile image
Bob •

I don't understand how this service was even considered a good idea... this is like bugging your own house, except worse.

Collapse
 
destro_mas profile image
Shahjada Talukdar The Destro Dev Show •

I agree with your point!
As I already mentioned in another comment - "no one should run ngrok in their machine for more than a few mins."

Collapse
 
shaijut profile image
Shaiju T •

Nice 😄, I have used this to debug a webhook. I agree with others in comments that Security point of view its not good. But i think this is the only option to debug a webhook , isn't ?

Collapse
 
destro_mas profile image
Shahjada Talukdar The Destro Dev Show •

We can still deploy webhook to a server( let's say heroku) and see the Debug Logs there.
But sure, that will be time-consuming to change code each time and deploy it, and then see the logs.
ngrok will be faster.

Collapse
 
buckldav profile image
David •

ngrok does have some great use cases for DEVELOPMENT. I like using it as a "localhost with https" to test parts of my apps that check for a secure connection. Like mentioned in other comments, "no one should run ngrok in their machine for more than a few mins." Check ngrok.com/product for possible use cases.

Collapse
 
destro_mas profile image
Shahjada Talukdar The Destro Dev Show •

Yeah, HTTPS is a good use case.
And right, as you quoted my line - "no one should run ngrok in their machine for more than a few mins." 👍