Appearance
Local Tunneling โ
Share your local development site with anyone, anywhere.
Local tunneling creates a secure bridge between your computer and the internet. Instead of deploying to a staging server, you can instantly share your localhost site with clients, teammates, or testers.
Why use tunnels? โ
- ๐ Quick demos โ Show clients your work without deploying
- ๐งช Test webhooks โ Receive payments, emails, or API callbacks on localhost
- ๐ฅ Remote testing โ Let teammates view your site from their devices
- ๐ Secure access โ Encrypted connections with optional password protection
Alternatives to ngrok, localtunnel, and similar tunnel services.
Set Up Tunnel Services โ
Tunnel services expose your local development sites to the internet via SSH, allowing you to share work with clients, test webhooks, or test on mobile devices. AMP Manager uses simple SSH-based tunnel services that don't require downloading extra software or complex authentication.
How It Works โ
AMP Manager integrates with SSH-based tunnel services. Your local sites run on Angie server (port 8080) with virtual host configuration. The tunnel service forwards requests from a public URL to your local server.
Quick Summary:
- Click Start Tunnel in AMP Manager
- Tunnel service creates a public URL (e.g.,
myproject.localto.net) - Anyone on the internet can visit that URL
- Requests route back through SSH tunnel to Angie
- Angie serves the correct domain based on the Host header
This lets you share your local development with students, mentors, or colleagues instantly - no deployment needed.
Supported Services โ
| Service | Subdomain Format | Auth | Setup Required |
|---|---|---|---|
| localhost.run | {random}.localhost.run | None | None |
| Serveo | {name}.serveousercontent.com | None | None |
| Localtonet | {name}.localto.net | Token | Free account |
Placeholders โ
When configuring tunnel commands, use these placeholders:
| Placeholder | Description | Example |
|---|---|---|
{domain} | Full local domain | myproject.local |
{port} | Local server port | 8080 |
localhost.run โ
The simplest option - no setup required. The service assigns a random subdomain automatically.
bash
ssh -R 80:{domain}:8080 nokey@localhost.run
# Example: ssh -R 80:myproject.local:8080 nokey@localhost.run
# -> https://{random}.localhost.run- Setup: None - works out of the box
- Pros: Zero configuration, automatic HTTPS, completely free
- Cons: Random subdomain (changes each session), no custom names
- Best for: Quick testing, sharing with clients temporarily
WordPress โ
WordPress stores absolute URLs in the database. When using a tunnel, the public URL differs from your local *.local domain.
Required Configuration:
Add to your wp-config.php:
php
// Use the tunnel URL dynamically
$scheme = isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on' ? 'https' : 'http';
define('WP_HOME', $scheme . '://' . $_SERVER['HTTP_HOST']);
define('WP_SITEURL', $scheme . '://' . $_SERVER['HTTP_HOST']);Alternative (plugin):
- Install Relative URL plugin
- Sets all URLs to relative paths
Important: Free subdomains change on reconnect. For persistent WordPress development, consider:
- Custom Domain plan from localhost.run
- Use Localtonet for stable URLs (free account, custom subdomain)
Laravel โ
Laravel generally works well with tunnels out of the box. One consideration:
APP_URL Configuration:
For proper URL generation in emails, notifications, and asset URLs:
bash
# In your .env file - tunnel will override this
APP_URL=https://your-tunnel-url.localhost.runFor dynamic detection:
php
// In config/app.php
'url' => env('APP_URL', 'http://localhost'),Most Laravel apps work seamlessly - the tunnel handles the routing correctly.
Serveo โ
Similar to localhost.run but allows custom subdomain names.
bash
ssh -R {name}:80:{domain}:8080 serveo.net
# Example: ssh -R myproject:80:myproject.local:8080 serveo.net
# -> https://myproject.serveousercontent.com- Setup: None - works out of the box
- Pros: Custom subdomain possible, no setup required, free
- Cons: Subdomain may be taken if you want a popular name
- Best for: Named tunnels without any account
Localtonet โ
Requires a free account and token from localtonet.com. The service provides a user-friendly dashboard and supports persistent URLs.
bash
ssh -p 223 -R {name}:80:{domain}:8080 YOUR_TOKEN@localto.net
# Example: ssh -p 223 -R myproject:80:myproject.local:8080 mytoken@localto.net
# -> https://myproject.localto.net- Setup: Create free account at localtonet.com, generate token in dashboard
- Pros: Custom subdomain, persistent URLs, free dashboard to manage tunnels
- Cons: Requires token, different SSH port (223)
- Best for: Persistent tunnels with your own subdomain
Getting your token:
- Visit localtonet.com/register to create an account
- Log in to the Dashboard
- Go to Tunnels -> New Tunnel -> Select HTTP
- Click Settings -> SSH Command to get your one-liner
- Copy the token portion (before
@) and add to Credentials in AMP Manager
Reference: See Localtonet Zero-Install SSH Docs for more details.
WordPress โ
Same configuration as localhost.run - add to wp-config.php:
php
$scheme = isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on' ? 'https' : 'http';
define('WP_HOME', $scheme . '://' . $_SERVER['HTTP_HOST']);
define('WP_SITEURL', $scheme . '://' . $_SERVER['HTTP_HOST']);Advantage over localhost.run: Localtonet persistent URLs don't change, so WordPress URL updates are one-time only.
Laravel โ
Works out of the box. Set your .env:
bash
APP_URL=https://myproject.localto.netSetup Steps โ
- Go to Settings -> Tunnel Services
- Enable your preferred tunnel provider
- For Localtonet: Add your token to Credentials
- Open domain details and click Start Tunnel
- Copy the public URL to share
Use Cases โ
- Share local site with client
- Test webhooks from external services (Stripe, GitHub, etc.)
- Mobile testing on real URL
- Demo prototypes without deployment
Other Tunnel Services โ
AMP Manager includes the most popular SSH-based tunnel services. If you need to use other services like Cloudflare Tunnel, ngrok, or localtunnel, you can still connect them to your local development environment.
Key Information:
- Angie server listens on port 8080
- Use
{domain}:8080as your local target (e.g.,myproject.local:8080) - This tells the tunnel service which virtual host to serve
Example:
bash
# Cloudflare Tunnel
cloudflare tunnel --url localhost:8080
# Or with specific domain:
cloudflare tunnel --url myproject.local:8080
# ngrok
ngrok http myproject.local:8080Requirements for other services:
- Download their CLI binary (place in PATH or
/bin) - Configure API authentication (token, account)
- Different setup than SSH-based services
See Also โ
- For Users - Complete beginner guide
- Workflows & Deployment - Deployment deep dive
- Troubleshooting - Common issues
- Glossary - All terms explained
