Quickstart
Get Portless up and running in under 2 minutes.Installation
Install Portless globally
Install via npm:
Portless requires Node.js 20+ and works on macOS and Linux.
Run your first app
Navigate to any project and run your dev server through Portless:Or specify a name explicitly:The proxy will auto-start if needed, and your app will be available at:
First Commands
Run with Auto-Inferred Name
Portless automatically infers your project name frompackage.json, git repo, or directory:
Run with Explicit Name
Specify the name directly:Use Subdomains
Organize related services under the same domain:Add to package.json
Make Portless the default for your project:package.json
npm run dev and get a stable URL.
The proxy auto-starts when you run an app. You can also start it explicitly with
portless proxy start.Working Example
Let’s say you’re building a full-stack app with a Next.js frontend and an Express API.Git Worktree Support
If you use git worktrees, Portless automatically detects them and prepends the branch name as a subdomain:portless run in your package.json once and it just works everywhere - the main checkout uses the plain name, and each worktree gets a unique subdomain. No --force needed, no name collisions.
Managing the Proxy
The proxy starts automatically when you run an app, but you can also control it manually:Environment Variables Injected
When you run an app through Portless, these environment variables are automatically injected:| Variable | Description | Example |
|---|---|---|
PORT | The port your app should listen on | 4123 |
HOST | The host your app should bind to | 127.0.0.1 |
PORTLESS_URL | The public URL to access your app | http://myapp.localhost:1355 |
PORT and HOST. For frameworks that don’t, Portless auto-injects the correct flags.
Static Aliases (Advanced)
If you have a service running outside of Portless (like a Docker container), you can register it manually:Next Steps
Why Portless?
Learn about the problems Portless solves and real-world use cases
Environment Variables
Configure Portless with environment variables and advanced options