Clean vanity URLs for private Go modules
Hide internal repo paths and server IPs behind short, stable import URLs.
One command to set up, works with any Git host.
import "github.com/yourorg/private-module"
// Before — self-hosted Git server
import "192.168.1.100/yourorg/private-module"
// After
import "gomod.io/your/private-module" // gomod.io (default)
import "go.yourcompany.com/private-module" // custom domain
Install & use in 30 seconds
Step 1. Install the CLI:
curl -fsSL gomodvanityurls.com/install.sh | bash
Windows? Works in Git Bash, WSL/WSL2, and MSYS2. For PowerShell/CMD:
scoop bucket add gomodvanityurls https://github.com/gomodvanityurls/scoop-bucket && scoop install gvu
Step 2. Add a vanity URL:
gvu add gomod.io/private-module https://github.com/yourorg/private-module.git
Step 3. Configure Go environment:
export GOPRIVATE=gomod.io
Step 4. Use it:
import "gomod.io/private-module"
Important: Your module’s
go.modmust declare the vanity URL as its module path (e.g.,module gomod.io/private-module), not the original repo URL likegithub.com/yourorg/private-module.
Step 1. Install the CLI and set up your account:
curl -fsSL gomodvanityurls.com/install.sh | bash
gvu auth signup
gvu auth bind user@example.com
Windows? Works in Git Bash, WSL/WSL2, and MSYS2. For PowerShell/CMD:
scoop bucket add gomodvanityurls https://github.com/gomodvanityurls/scoop-bucket && scoop install gvu
Step 2. Point your DNS (must be done before adding the route):
go.yourcompany.com CNAME gomodvanityurls.com
Step 3. Add a custom domain route:
gvu add go.yourcompany.com/private-module https://github.com/yourorg/private-module.git
Step 4. Configure Go environment:
export GOPRIVATE=gomod.io,go.yourcompany.com
Step 5. Use it:
import "go.yourcompany.com/private-module"
Important: Your module’s
go.modmust declare the vanity URL as its module path (e.g.,module go.yourcompany.com/private-module), not the original repo URL likegithub.com/yourorg/private-module.
Features
- One-command setup — install CLI, add route, done
- Custom domains — use your own domain with automatic TLS certificates
- Passwordless auth — email OTP, no password to manage
- Credentials stay local — your access token and Git credentials live only on your machine; the server never stores your SSH keys or repo passwords
- Monorepo support — serve multiple Go modules from a single repo with Go 1.25 subdirectory routing (
--subdir)