Next-Gen App & Browser Testing Cloud
Trusted by 2 Mn+ QAs & Devs to accelerate their release cycles

ngrok turns your localhost into a public URL in seconds. Learn what ngrok is, how it works, whether it is safe and free, and how to use it for testing.

Chandrika Deb
Author
June 22, 2026
ngrok is a reverse proxy that gives your locally running app, API, or webhook endpoint a public URL in seconds, without deploying it or touching your firewall. You run a small agent on your machine, ngrok opens a secure tunnel to its cloud, and traffic to the public URL is forwarded straight to your localhost.
That single trick solves a surprising number of everyday problems: receiving webhooks on a laptop, showing a work-in-progress build to a client, or testing an integration that demands a real HTTPS URL. This guide explains what ngrok is, how it works, whether it is safe and free, and where a testing-cloud tunnel is the better fit.
Overview
ngrok is a globally distributed reverse proxy that exposes a service on your local machine to a public URL through a secure, outbound tunnel, so you can share or test it without deploying or reconfiguring your network.
What ngrok does:
When to reach past ngrok:
ngrok is a reverse proxy that gives a service running on your own machine a public URL. ngrok's documentation describes it as a globally distributed reverse proxy that acts as the front door to your applications, wherever they run.
In plain terms, it takes something only you can reach at http://localhost and makes it reachable on the open internet at a URL like https://your-name.ngrok-free.app. Nothing about your app changes. You do not deploy it, buy a server, open a port, or edit DNS.
That is why ngrok became a default tool in so many developer toolkits: the gap between "running on my laptop" and "reachable by the outside world" usually takes infrastructure work, and ngrok closes it with a single command.
ngrok works through two pieces: a lightweight agent you run locally and ngrok's cloud edge. The agent does not wait for inbound connections, which is what makes it firewall friendly.
Because the connection is outbound and encrypted, your local app is never directly exposed to the internet. Visitors only ever talk to ngrok's edge, and the edge talks to your machine over the tunnel you opened.
ngrok shows up wherever a local service suddenly needs to be reachable from outside. The most common uses are:
The through-line is speed. Each of these tasks normally needs a deploy or an infrastructure change, and ngrok replaces that with one command.
Getting a public URL takes three steps: install the agent, connect it to your account, and start a tunnel.
Install the agent with a package manager or download it for your operating system, then add the authtoken from your ngrok dashboard so the agent is tied to your account.
# Install (pick one)
brew install ngrok # macOS
choco install ngrok # Windows
npm install -g ngrok # any OS with Node.js
# Connect the agent to your account
ngrok config add-authtoken <YOUR_AUTHTOKEN>Point ngrok at the local port your app already runs on. If your dev server is on port 3000, one command exposes it:
$ ngrok http 3000
Session Status online
Account your-name (Plan: Free)
Forwarding https://abc123.ngrok-free.app -> http://localhost:3000
Connections ttl opn rt1 rt5
0 0 0.00 0.00The Forwarding line is the public URL. Share it, paste it into a webhook configuration, or open it on another device. Visit the local inspection interface (usually http://127.0.0.1:4040) to watch and replay requests as they come in.
ngrok the tool is safe and encrypted; the risk lives in how a tunnel is used. The traffic between the agent and ngrok's edge is encrypted, and the tool is a legitimate, widely used product.
It is worth knowing the security context, though. MITRE ATT&CK catalogs ngrok as a legitimate reverse proxy that attackers also abuse, for example to tunnel command-and-control traffic or quietly proxy connections through a firewall. The tool is not malicious; the same capability that helps you is useful to an intruder.
For everyday development, treat a tunnel like an open door and follow a few habits:
Yes, ngrok has a free plan, with limits. The free tier is enough to learn the tool and handle light webhook and demo work, and it now includes a free assigned dev domain, so you are not handed a brand-new random URL on every run.
The free plan also carries usage limits on things like monthly requests, bandwidth, and how many tunnels you can run at once, and it shows visitors an interstitial warning page before they reach your app. Paid plans remove that warning page, raise the limits, and unlock custom domains and team features. Because these limits change over time, confirm the current numbers on ngrok's pricing page before you rely on them.
For short-lived sharing and webhook debugging, the free plan is usually plenty. For an always-on endpoint or anything customer-facing, a paid plan or a reserved domain is the more dependable choice.
ngrok is great for getting eyes on a local build, and that includes opening it manually on a phone or a colleague's machine. Where it stops is automated testing: ngrok hands you a URL, but it does not run your cross-browser tests across operating systems and real devices.
That is the job of a testing-cloud tunnel. TestMu AI Underpass creates an outbound, SSH-encrypted tunnel from your machine to the TestMu AI cloud, so cloud browsers can reach your local or staging server without it being publicly exposed. Your app stays private, and the grid does the testing.
The practical difference for a QA workflow:
A useful rule of thumb: reach for ngrok when a human needs to see your local app, and reach for a testing-cloud tunnel when a test suite needs to run against it at scale.
ngrok earns its place in the toolkit by solving one problem cleanly: it turns localhost into a public URL in seconds, with no deploy and no network changes. That makes it ideal for webhooks, quick demos, and integrations that need a real address.
Just keep its boundaries in mind. Treat each tunnel as a public door, mind the free-plan limits, and when the goal shifts from "let me show this" to "let me test this everywhere," move to a testing-cloud tunnel like TestMu AI Underpass so your local build can run across real browsers and devices while staying private. Start testing your local builds on the TestMu AI cloud and let the grid do the work.
Did you find this page helpful?
More Related Hubs
TestMu AI forEnterprise
Get access to solutions built on Enterprise
grade security, privacy, & compliance