Your dev flow first
Keep the package manager and command your team already uses. Localghost detects the project flow and guides the first run when setup is missing.
Buh. Friendly local dev domains.
A tiny CLI for the local dev flow you already use. Install with npm, pnpm, Yarn, or Bun, run localghost, and get a clean browser-facing .localhost URL.
# install with npm, pnpm, Yarn, or Bun localghost local: http://app.localhost/ target: http://127.0.0.1:5173/
Keep the package manager and command your team already uses. Localghost detects the project flow and guides the first run when setup is missing.
Project names come from package.json, port 5173 is the fallback, HTTP is default, dynamic ports are on, and www. aliases are included.
Set explicit server.allowedHosts entries without opening the broad allowedHosts: true shortcut.
Keep local HTTP by default. Turn on Caddy HTTPS with https: true or --https, then trust the local CA only when you choose.
Most repos do not need localghost.config.mjs. Add it only for nonstandard ports, HTTPS, fixed ports, or custom alias behavior.
Generated setup lives under ops/local/, and reset lets you retest the first-run flow without deleting your .localghost contract.
ghostTunnel is an opt-in preview of stable wildcard sharing routes like plan-summer-base-hamed.ghost.moonlit-otter.example.
Experimental: configuration, transports, CLI behavior, and public APIs may change between releases. Do not rely on Ghost Tunnel for production-critical access.
Build names from route, project, and owner, then point *.ghost.<your-domain> at the deployed app.
Enable it explicitly with ghostTunnel: true or a ghostTunnel.preview object in localghost.config.mjs.
Requests are checked for host shape, HTTPS, auth, DNS-safe labels, and relay target policy before serving a tunnel surface.
Run localghost release patch to dispatch the guarded pipeline. GitHub Actions verifies, versions, tags, publishes with provenance, and creates release notes.
Runtime dependencies are limited to commander and execa. Vite stays an optional peer for projects that use the plugin.
No postinstall scripts, hidden Homebrew commands, or full hosts-file rewrites. Localghost changes only its managed block.