Use this whenever something running on your own machine (like a self-hosted n8n instance) needs to receive webhooks or messages from the internet, and you don't want to pay for cloud hosting just to get a public URL.
Steps
- Sign up free at ngrok.com, email only, no card required.
- In the dashboard, find your assigned dev domain, something like
abc123xyz.ngrok-free.dev. This is yours permanently as long as the account exists. - Install the ngrok CLI for your OS.
- Copy your authtoken from the dashboard and run:
ngrok config add-authtoken YOUR_TOKEN - Start the tunnel, pointing at whatever local port your service runs on:
ngrok http --url=abc123xyz.ngrok-free.dev 5678 - Leave that terminal window open, closing it stops the tunnel.
Gotcha
The free static domain does not expire and does not rotate on restart, which used to be true of ngrok's older free tier. As of now, the free plan includes one permanent dev domain with no timeout on the endpoint, meaning it's genuinely safe to rely on for a personal project, not just for quick testing.
Quick reference
ngrok config add-authtoken YOUR_TOKEN
ngrok http --url=yourdomain.ngrok-free.dev PORT