HTTP Tunnels

A public, HTTPS URL that points at your local dev server.

How it works

The CLI opens a secure connection to the PreviewBox edge and forwards traffic from your public URL back to localhost. Nothing needs to be deployed, and you don't need to touch your router or firewall.

Start an HTTP tunnel
prevbox serve http 3000
# → https://happy-fox-42.previewbox.dev → localhost:3000

HTTPS by default

Every tunnel gets a valid TLS certificate automatically, so your URL is always https://. That means webhooks, browser APIs and mobile apps that require a secure origin just work.

Custom subdomains

Skip the subdomain in the CLI to get a random one, or pick your own so the URL is easy to remember and share:

Custom subdomain
prevbox serve http 3000 --subdomain my-app
# → https://my-app.previewbox.dev

Subdomains stay reserved for 7 days once a tunnel has been idle for an hour (deleted tunnels reserve immediately). While reserved, only you can reuse the subdomain — so a URL you shared for a live demo can't be squatted by someone else. During the first hour after a disconnect the name is still free, and once the 7 days pass it's released for anyone to claim.

Multiple tunnels

Run as many tunnels as you need — different ports, different subdomains, or a mix of HTTP and TCP. From the TUI's Serve page, type another target and press Enter; press s to stop them all.

Every tunnel appears in the dashboard with live request counts, latency and bandwidth — plus request logs you can follow in real time.

Good use cases

  • Webhook testing — give Stripe, GitHub or Twilio a URL that hits your local machine.
  • Demos — show clients and stakeholders your work without deploying.
  • Mobile testing — open your localhost from a phone over the internet.
  • Team reviews — share a work-in-progress branch without pushing to staging.

Running a non-HTTP service like a Minecraft server? See TCP tunnels.