OctoPrint Remote Access: Tailscale, VPN, No Port Forwarding
Set up OctoPrint remote access with Tailscale, WireGuard, an authenticated proxy or OctoEverywhere, with checks for login, webcam access and routing.
OctoPrint remote access needs a protected route from your phone or laptop to the host. Tailscale is a practical starting point when you can install its client on both devices. WireGuard suits an existing VPN setup; OctoEverywhere provides a plugin and hosted relay. An authenticated reverse proxy is another layer for a maintained installation. The configurations below describe these routes and the checks to make before depending on one.
Start with a working local connection. The Raspberry Pi setup guide covers first boot and account creation. If the printer itself stops, use the serial-link and host troubleshooting guide: a remote browser and the printer’s USB connection are separate parts of the system.
Why not to port forward OctoPrint
The OctoPrint project’s guidance advises against putting the printer interface directly on the public internet. A login screen does not remove the exposure of the application behind it. OctoPrint controls movement and heaters, so access has consequences beyond viewing a dashboard.
Do not forward the OctoPrint HTTP port, its camera port or SSH just to check a print remotely. An existing WireGuard gateway may need an inbound UDP port for the VPN itself; that is different from publishing OctoPrint’s web service. If the connection cannot accept inbound traffic, use an outbound connection such as Tailscale or the relay described below.
Choose the access route
| Method | Client requirement | What you maintain | Useful when |
|---|---|---|---|
| Tailscale | Enrolled client on each device | Device membership and access rules | Your own phone and laptop need access |
| WireGuard | A configured VPN peer | Keys, endpoint and firewall rules | You already manage a reachable VPN endpoint |
| Authenticated proxy inside a VPN | VPN access plus browser credentials | Proxy, certificates and backend restrictions | You want another login before the application |
| OctoEverywhere | Browser and linked service account | Plugin and account access | You prefer a hosted relay workflow |
These are workflow choices, not measured performance rankings. A sensible selection question is which account, device or service you can revoke promptly when it is no longer needed.
Tailscale: connect the host and your device
Follow the Linux installation instructions for the host’s distribution. After installing the package, enroll the host:
sudo tailscale up
tailscale status
tailscale ip -4
Complete the browser authorization shown by the first command. Install Tailscale on the remote phone or laptop, sign in to the same network, and confirm both devices appear in the administration console. Use the host’s Tailscale address with its existing web port. This assumes that the web service listens on an address reachable through the VPN and the host firewall permits that connection.
For an OctoPi installation whose local web frontend responds at http://127.0.0.1:80, Tailscale Serve can provide a private HTTPS entry point:
sudo tailscale serve --bg http://127.0.0.1:80
tailscale serve status
Follow any HTTPS setup prompt and use the address that Serve prints. For a manual OctoPrint installation, substitute its actual local listening port. Check that address locally before configuring the proxy; port 80 is an assumption for this example, not a requirement of OctoPrint.
The Serve reference documents persistent background service and status inspection. Serve shares within the Tailscale network. Keep this setup private; Funnel is a separate public-sharing feature and is unnecessary here.
Review the access policy instead of assuming that enrollment gives only the access you intended. Permit the operator’s devices to reach the chosen web entry point and avoid granting unrelated devices broad access to the host. Existing broad rules can still grant access, so adding a narrow rule alone is not a restriction. Keep SSH authorization separate from permission to view OctoPrint.
Try the URL from your phone with Wi-Fi disabled and Tailscale connected. Then disconnect Tailscale: the private URL should cease to be reachable over that connection. Check the camera and live temperature updates as well as the initial page; loading HTML alone does not establish that the whole interface works.
WireGuard: a direct host tunnel
An existing router VPN can provide access to the printer network using its own documented routing and firewall setup. For a smaller example, the OctoPrint host itself can be the WireGuard endpoint. This avoids routing through it to other LAN machines. The following pair uses an illustrative 10.77.0.0/24 tunnel network; choose a different range if it overlaps your networks.
Install WireGuard for each operating system. Generate a separate key pair on each device according to the Quick Start. Keep private keys on their own devices and exchange public keys. The uppercase values below are labels to replace with locally generated values, not usable credentials.
Host configuration, /etc/wireguard/wg0.conf:
[Interface]
Address = 10.77.0.1/24
ListenPort = 51820
PrivateKey = HOST_PRIVATE_KEY
[Peer]
PublicKey = CLIENT_PUBLIC_KEY
AllowedIPs = 10.77.0.2/32
Remote client configuration:
[Interface]
Address = 10.77.0.2/32
PrivateKey = CLIENT_PRIVATE_KEY
[Peer]
PublicKey = HOST_PUBLIC_KEY
Endpoint = vpn.example.com:51820
AllowedIPs = 10.77.0.1/32
PersistentKeepalive = 25
Replace the example endpoint with your reachable VPN hostname. If the host is behind your router, forward only the selected WireGuard UDP port to it. A connection behind carrier-grade NAT may not provide this inbound route. Permit the VPN handshake and web traffic from the client tunnel address in the host firewall; leave public web access blocked.
Protect the configuration files because they contain private keys. On Linux, start the interface with sudo wg-quick up wg0 and inspect sudo wg show after activating the client. The wg-quick manual explains how interface addresses and routes follow the configuration. The client routes only the host’s tunnel address in this example. No LAN forwarding or internet exit-node function is configured.
Open http://10.77.0.1/ if the local frontend listens on port 80 and accepts tunnel traffic. Keepalive helps a client behind NAT retain its mapping; omit it when unnecessary. A handshake without a working webpage suggests checking the service binding, chosen port and firewall separately.
Reverse proxy with authentication
For a proxy you maintain yourself, put it inside the VPN and keep OctoPrint’s own login enabled. This example uses Caddy on the OctoPi host, with a private hostname resolving to that host. Port 8443 avoids taking over an existing frontend on ports 80 or 443.
Create a password hash interactively with caddy hash-password. The basic_auth directive accepts a hash, so replace the label below with the generated result. Use a distinct proxy password.
https://printer.home.arpa:8443 {
tls internal
basic_auth {
operator REPLACE_WITH_GENERATED_PASSWORD_HASH
}
reverse_proxy 127.0.0.1:80 {
header_up -Authorization
}
}
Configure private DNS or a client hosts entry for the hostname you choose. Install this Caddy instance’s local CA certificate into the authorized client’s trust store through a trusted local channel, following the local HTTPS documentation. Do not train the operator to ignore certificate warnings. Keep the listener restricted by firewall to the VPN clients; this example does not publish a public domain or require a public HTTP port.
The proxy forwards to the existing local frontend, so preserve its camera routes. Caddy’s reverse proxy supports WebSocket connections. Removing the upstream Authorization header keeps the proxy’s Basic credentials out of OctoPrint; this recipe is for browser sessions, so integrations using that header need a separately considered setup.
Validate the Caddyfile before loading it. Check the proxy login in a private browser window, then sign in to OctoPrint. Confirm the webcam, live status and file list work. Restrict direct backend access so a client cannot simply use another reachable port to avoid the extra login.
If redirects or download URLs use the wrong scheme, review OctoPrint’s reverse proxy settings. Trust only the actual proxy addresses and account for any existing OctoPi proxy between Caddy and OctoPrint. A generic pasted trusted-network range is not a substitute for knowing that request path.
OctoEverywhere: an outbound relay
The OctoEverywhere setup flow starts with its OctoPrint plugin. In Settings, open Plugin Manager, find the plugin and install it. Restart while the printer is idle, then follow the setup link shown in the interface to associate the printer with your service account.
Open the linked printer from the service dashboard on a phone using mobile data. Confirm the expected printer identity and camera view. Keep the local OctoPrint account credentials available too: a successful service connection should not be your only way to administer the machine.
The plugin listing describes remote access and monitoring features. Consult its current service terms for feature limits instead of assuming that every integration or stream is unlimited. The operational tradeoff is dependence on the hosted service and its account system. If you retire the service, remove the association and plugin access, then check that the local interface still works.
Accounts, cameras and application keys
OctoPrint’s access controls include an administrator account and narrower user groups. For a monitoring account, inspect the read-only permissions before granting printer control. Keep guest permissions empty and automatic login disabled for this setup.
The webcam is a separate service embedded in the page; OctoPrint’s login does not automatically protect its stream URL. Route both the stream and snapshots through the protected connection, and check that a copied camera URL does not provide unintended access from outside it.
Use an application-specific key for compatible apps so you can manage each authorization separately. Treat it as a secret with the associated user’s permissions. Revoke unused app keys when changing phones or retiring integrations, and remove lost devices from the VPN or relay account as well. A browser logout does not revoke a separately issued application key.
A repeatable connection check
Record the local URL, remote URL, selected method and where each authorization is managed. With the printer idle, confirm access from an authorized remote device, verify the camera and status updates, then repeat with the VPN disconnected or proxy session signed out. The expected failure is part of the check.
If the interface disappears during a print, first establish whether the machine is still printing. Avoid restarting a host that is feeding an active job merely to fix the browser. Work through the disconnect diagnostic order locally when necessary. Remote access adds visibility; firmware heater protections and appropriate physical supervision remain separate requirements.
Sources
- OctoPrint: safe remote access guidance
- OctoPrint docs: Access Control
- OctoPrint docs: Application Keys plugin
- Tailscale: install on Linux
- Tailscale: Serve command reference
- Tailscale: access control grants
- WireGuard: Quick Start
- WireGuard tools: wg-quick manual
- Caddy: basic_auth directive
- Caddy: reverse_proxy directive
- Caddy: automatic HTTPS and local certificates
- OctoPrint docs: server and reverse proxy configuration
- OctoEverywhere: setup instructions
- OctoPrint Plugin Repository: OctoEverywhere
Related
OctoPrint Raspberry Pi Setup: Hardware and First Boot
Which Raspberry Pi to buy for OctoPrint, the power supply and cable choices that actually matter, and how to get through first boot without a stall.
OctoPrint Disconnects Mid-Print: Causes and Fixes
A diagnostic order for OctoPrint disconnects and communication errors, from undervoltage and USB noise to plugin faults and starved serial buffers.
OctoPrint Plugins Worth Installing (and Which to Skip)
Which OctoPrint plugins are worth installing on a Raspberry Pi host: what each one fixes, what it costs the host and serial link, and how to check it.