npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

opentunnel-cli

v1.0.25

Published

Self-hosted tunnel solution to expose local ports to the internet via custom domains, ngrok, or Cloudflare Tunnel

Readme


Quick Start

Installation

npm install -g opentunnel-cli

As a Client

Connect to an existing OpenTunnel server:

# Quick tunnel
opentunnel quick 3000 -s example.com

# With authentication
opentunnel quick 3000 -s example.com -t YOUR_TOKEN

# Custom subdomain
opentunnel quick 3000 -s example.com -n myapp
# → https://myapp.op.example.com

As a Server

Host your own tunnel server:

# Public server
opentunnel server -d --domain example.com --letsencrypt --email [email protected]

# Private server (with auth)
opentunnel server -d --domain example.com --letsencrypt --email [email protected] --auth-tokens "SECRET"

DNS Setup: Point op.example.com and *.op.example.com to your server IP.

Home Use (Hybrid Mode)

Run server + tunnel in one terminal:

# Set default domain (one time)
opentunnel setdomain yourdomain.com

# Expose any port
opentunnel expl 3000

Using ngrok or Cloudflare Tunnel

Don't have a server? Use third-party tunnel providers:

# With Cloudflare Tunnel (free, no account needed for quick tunnels)
opentunnel http 3000 --cloudflare
opentunnel http 3000 --cf

# With ngrok
opentunnel http 3000 --ngrok
opentunnel http 3000 --ngrok --region eu

Authentication & Named Tunnels

Store credentials securely and manage Cloudflare named tunnels:

# Login to providers
opentunnel login cloudflare       # Opens browser for OAuth
opentunnel login ngrok --token YOUR_TOKEN

# Create and manage named tunnels
opentunnel create my-tunnel --cf
opentunnel tunnels --cf
opentunnel route my-tunnel app.example.com
opentunnel delete my-tunnel --cf

# Use named tunnel with -n flag
opentunnel http 3000 --cf -n my-tunnel

# View stored credentials
opentunnel config list

Documentation

| Guide | Description | |-------|-------------| | Client Guide | Complete client usage and options | | Server Guide | Server deployment and configuration | | Commands Reference | All CLI commands and options | | Configuration File | opentunnel.yml reference | | Home Use Guide | Running from home with port forwarding | | Domain Setup | DNS and SSL configuration | | DuckDNS & Free DNS | Free DNS services setup | | Cloudflare Tunnel | Cloudflare Tunnel & named tunnels | | Multi-Domain | Multiple domains on one server | | Authentication | Token-based authentication | | IP Access Control | Allow/deny IP ranges (cross-provider) | | Firewall (Dymo API) | Fraud detection and bot protection |


Architecture

┌─────────────────────────────────────────────────────────────────┐
│                         INTERNET                                │
│   Users access: https://myapp.op.example.com                   │
└──────────────────────────────┬──────────────────────────────────┘
                               │
                               ▼
┌─────────────────────────────────────────────────────────────────┐
│                    OpenTunnel Server                            │
│                    (op.example.com)                             │
│   - Routes by subdomain                                         │
│   - Forwards via WebSocket                                      │
└──────────────────────────────┬──────────────────────────────────┘
                               │ WebSocket
                               ▼
┌─────────────────────────────────────────────────────────────────┐
│                      Your Computer                              │
│                  (behind NAT/firewall)                          │
│   ┌──────────────┐  ┌──────────────┐  ┌──────────────┐         │
│   │  Web App     │  │  API Server  │  │  Database    │         │
│   │  :3000       │  │  :4000       │  │  :5432       │         │
│   └──────────────┘  └──────────────┘  └──────────────┘         │
└─────────────────────────────────────────────────────────────────┘

License

Proprietary License - All rights reserved.

  • ✅ Personal, educational, and commercial use allowed
  • ❌ No forks or redistribution without permission
  • ❌ No reselling without explicit consent

Contact FJRG2007 for licensing questions.