development
free open source software
tunneling
agrinman, api testing, async-io, backend development, Developer Tools, devops, localhost tunnel, network proxy, ngrok alternative, open source, port forwarding, remote access, rust, rust programming, secure tunnel, self-hosted tunnel, tokio, tunnelto, web development, webhook testing
9M2PJU
0 Comments
Meet Tunnelto: The High-Performance Open-Source Tunnel Written in Rust
Every developer has been there. Youโre building a webhooks integration, testing a mobile app against your local API, or trying to show a client a preview of a site. You need a public URL for your localhost, and you need it now.
While Ngrok has been the industry standard for years, it has become increasingly bloated, restricted, and expensive. Enter tunnelto, an open-source, blazingly fast alternative built entirely in Rust.
Why Tunnelto?
If youโre already using a tunneling tool, why switch?
- Written in Rust: Built on top of
tokioandasync-io, itโs designed for high concurrency and minimal resource footprint. - Open Source: Unlike proprietary alternatives, you can see exactly how your data is being handled.
- Self-Hostable: If you don’t want to use the public service, you can deploy your own
tunnelto_serverusing Docker or fly.io. - Simplicity: No complex configuration files. One command and youโre live.
Getting Started in 60 Seconds
Installing tunnelto is straightforward, whether you’re on macOS or a Linux/Windows machine with Cargo.
Installation
macOS (via Brew):
Bash
brew install agrinman/tap/tunnelto
Via Cargo:
Bash
cargo install tunnelto
Creating Your First Tunnel
Suppose your local dev server is running on port 8000. To expose it to the world, simply run:
Bash
tunnelto --port 8000
tunnelto will provide you with a unique public URL (e.g., https://xyz.tunnelto.dev) that routes directly to your local machine.
Power User Features
While the quick start is great, tunnelto offers features that make it a robust choice for professional workflows:
1. Custom Subdomains
Tired of getting a random string every time you restart your tunnel? You can specify a preferred subdomain:
Bash
tunnelto --port 8000 --subdomain my-dev-project
2. Inspection Dashboard
tunnelto includes a local introspection dashboard. This allows you to monitor incoming requests, inspect headers, and debug the traffic hitting your local server in real-time.
3. Self-Hosting for Privacy
For teams with high security requirements, you can host the server component yourself. The repository includes a Dockerfile and a musl_build.sh script to make deployment to any cloud provider (like AWS, DigitalOcean, or Fly.io) trivial.
Under the Hood: The Tech Stack
What makes tunnelto interesting from a technical perspective is its architecture. It leverages:
- Tokio: The industry-standard asynchronous runtime for Rust.
- Control Streams: It uses a control websocket to coordinate tunnel creation and management.
- Gossip Mechanism: For those interested in distributed systems, the server implementation includes a gossip protocol to handle traffic across multiple server instances.
The Verdict
If you are looking for a tool that is faster, lighter, and more transparent than Ngrok, tunnelto is the answer. It stays out of your way and lets you get back to what matters: building your software.
Ready to try it? Check out the GitHub Repository and give it a star!



Post Comment