Skip to content

Quick tunnels

Terminal window
hytte --tunnel # or -t

hytte opens a tunnel to a public https:// address and logs it:

hytte listening on http://localhost:8000
Public tunnel URL: https://random-words-here.trycloudflare.com

Share that URL. hytte uses one of two services:

  1. Cloudflare quick tunnel, if cloudflared is installed. It’s fast, and you don’t need a Cloudflare account. You get a random *.trycloudflare.com address.
  2. localhost.run otherwise, through a built-in SSH client, so you install nothing. It’s slower. hytte pins localhost.run’s SSH host key on first use (in <data-dir>/known_hosts) and refuses to connect if it changes.

If the tunnel drops, hytte restarts it with backoff.

  • The address changes every time hytte starts. Sessions are tied to it, so everyone logs in again at the new URL. Setup links printed by hytte -u show localhost: replace the host with the tunnel URL. For a fixed address, use a named Cloudflare tunnel.
  • Passkeys and security keys aren’t offered on a quick tunnel, because they’re bound to a hostname and this one changes. Authenticator apps (TOTP) work everywhere. See Signing in.
  • The tunnel provider terminates TLS and can see traffic between the browser and hytte. With hytte that’s ciphertext plus metadata. The usual caveat applies: whoever sits in the middle delivers the JavaScript too. See the security model.
  • Combine with -s (hytte -s -t) to keep the local leg on HTTPS too. The tunnel skips the certificate check for that local connection.