GoTunnel¶
HTTP and TCP tunnels that put a local app or database on the internet with one command.
This repository hosts the prebuilt GoTunnel binaries, the docs, and the small launcher behind go install.
A side project, not a company. GoTunnel is a personal project by BakareDev, built to learn networking and systems design in Go. The hosted server is free with fair-use limits (30-minute sessions, 3 per day, one tunnel per device), provided as-is without guarantees, and may change or go offline. For anything important, self-host it.
Install¶
macOS and Linux:
curl -fsSL https://gotunnel.site/install.sh | sh
Windows (PowerShell):
irm https://gotunnel.site/install.ps1 | iex
With npm (Node.js 22+):
npm install -g gotunnel
With Go (1.21+):
go install github.com/bakare-dev/gotunnel-io/cmd/gotunnel@latest
Pick one method; you only need GoTunnel installed once.
The install scripts check the download against the release's SHA-256 checksums.txt, and the go install launcher and gotunnel update also verify that file's signature. npm relies on its own package integrity check. The install guide covers each one step by step, plus direct binary downloads, manual install, updating, uninstalling and troubleshooting. All builds are also on the releases page.
Quick start¶
Expose a local service (e.g. running on port 3000) through the free hosted server:
gotunnel http 3000
The first time you run it on a device, GoTunnel asks for your Gmail address and emails you a one-time code to register the device (one device per address). Your email is only used for that. After that, the device stays signed in and connects straight away.
You'll get a public https://<random>.t.gotunnel.site URL forwarding to your local port. Press q or Ctrl-C to stop.
Share a database or other TCP service¶
gotunnel tcp 5432
You get a host and port, e.g. k3x9m2qz7a.tcp.gotunnel.site:20017, that works with any normal client: psql, mysql, mongosh, redis-cli, ssh. TCP tunnels are locked: only IPs you allow with --allowlist, or that are approved through the link GoTunnel prints (the person connecting verifies their email once), can connect. See gotunnel tcp.
Update¶
Upgrade to the latest release in place:
gotunnel update
If you installed with npm, run npm install -g gotunnel@latest instead. See Update.
Uninstall¶
Remove GoTunnel from your computer:
gotunnel uninstall
It frees your email on the hosted server so you can register again later, on this or another device. Then it deletes your token and device ID, and the gotunnel binary. On macOS and Linux it asks for your password if the binary is in /usr/local/bin. On Windows it also removes the install folder from your PATH. If you installed with npm, it leaves the package alone; finish with npm uninstall -g gotunnel. See gotunnel uninstall for the options.
Commands¶
gotunnel http <port> Start a tunnel on the hosted server
gotunnel tcp <port> [--allowlist ip,cidr] Share a database or other TCP service, locked to approved IPs
gotunnel --server <host> --local localhost:<port> Start a tunnel against any server
gotunnel status Registration, token expiry, server reachability
gotunnel audit Security check of this machine's setup
gotunnel benchmark DNS / TCP / TLS / first-byte latency to the server
gotunnel inspect What this build supports and where its files live
gotunnel update Update to the latest release
gotunnel uninstall Remove GoTunnel and free your email for re-registration
gotunnel version Show the installed version
gotunnel help Show all options
Documentation¶
The docs below explain how GoTunnel works so you can understand what you're running before you trust it with your traffic.
| Document | What it covers |
|---|---|
| Download & install | Every install method, direct downloads, updating, uninstalling and troubleshooting |
| Command reference | Every command: http, tcp, status, audit, benchmark, inspect, update, uninstall, admin |
| Self-Hosting | Run your own GoTunnel server on a VPS instead of the hosted server |
| Architecture | How the client, server, tunnels, and security model fit together |
| Protocol | The binary wire protocol: frames, message types, and the session state machine |
| Changelog | What changed in each release |
Feedback and issues¶
Found a bug or have a request? Open an issue. If GoTunnel is useful to you, consider starring the repo to follow releases.