<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>VPS Security &#8211; Aveshost Blog</title>
	<atom:link href="https://blog.aveshost.com/tag/vps-security/feed/" rel="self" type="application/rss+xml" />
	<link>https://blog.aveshost.com</link>
	<description>Your Blueprint for Online Success</description>
	<lastBuildDate>Mon, 23 Nov 2026 11:31:46 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.1.5</generator>

<image>
	<url>https://blog.aveshost.com/wp-content/uploads/2026/01/logo-150x150.png</url>
	<title>VPS Security &#8211; Aveshost Blog</title>
	<link>https://blog.aveshost.com</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>How to Access OpenClaw Privately with Tailscale</title>
		<link>https://blog.aveshost.com/access-openclaw-privately-with-tailscale/</link>
					<comments>https://blog.aveshost.com/access-openclaw-privately-with-tailscale/#respond</comments>
		
		<dc:creator><![CDATA[James Wilson]]></dc:creator>
		<pubDate>Mon, 23 Nov 2026 11:31:44 +0000</pubDate>
				<category><![CDATA[AI Insights]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[AI agents]]></category>
		<category><![CDATA[OpenClaw]]></category>
		<category><![CDATA[self-hosting]]></category>
		<category><![CDATA[Tailscale]]></category>
		<category><![CDATA[VPS Security]]></category>
		<guid isPermaLink="false">https://blog.aveshost.com/?p=6138</guid>

					<description><![CDATA[A step-by-step guide on how to access OpenClaw privately with Tailscale Serve—keeping your Gateway bound strictly to loopback (127.0.0.1:18789) while serving automatic HTTPS over your private MagicDNS tailnet.]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">Knowing how to <strong>access OpenClaw privately with Tailscale</strong> lets you use your AI agent dashboard, webhooks, and control UI from any laptop or phone without ever exposing port <code>18789</code> to the public internet.</p>



<p class="wp-block-paragraph">Because OpenClaw has shell, file, and tool execution permissions, leaving its Gateway bound to <code>0.0.0.0</code> or behind an unauthenticated reverse proxy creates unnecessary risk. By keeping OpenClaw bound to <code>127.0.0.1</code> (loopback) and enabling <strong>Tailscale Serve</strong>, Tailscale terminates HTTPS certificates automatically over your private MagicDNS hostname and verifies tailnet identity before any request reaches your Gateway.</p>



<p class="wp-block-paragraph">Whether you host OpenClaw on <a href="https://www.aveshost.com/self-managed-vps-hosting" rel="noopener">self-managed VPS hosting</a> or <a href="https://www.aveshost.com/fully-managed-vps-hosting" rel="noopener">fully managed VPS hosting</a> with Aveshost, this guide walks through prerequisites, CLI and config setup, identity headers, and firewall verification.</p>



<div class="wp-block-rank-math-toc-block" id="rank-math-toc"><h2>Table of Contents</h2><nav><div><div><a href="#how-openclaw-and-tailscale-serve-work-together">How OpenClaw and Tailscale Serve Work Together</a></div><div><a href="#prerequisites-in-tailscale-admin-console">Prerequisites: MagicDNS, HTTPS Certificates, and Auth Mode</a></div><div><a href="#step-1-configure-openclaw-for-tailscale-serve">Step 1: Configure OpenClaw for Loopback + Tailscale Serve</a></div><div><a href="#step-2-enable-tailscale-identity-verification">Step 2: Verify Identity Headers and Connect Over HTTPS</a></div><div><a href="#step-3-lock-down-ufw-and-verify-no-public-exposure">Step 3: Verify Zero Public Exposure on Your VPS</a></div><div><a href="#faq">Frequently asked questions</a></div></div></nav></div>



<h2 id="how-openclaw-and-tailscale-serve-work-together" class="wp-block-heading">How OpenClaw and Tailscale Serve Work Together</h2>



<p class="wp-block-paragraph">If you are new to private mesh networking, our <a href="https://blog.aveshost.com/secure-vps-access-tailscale-without-public-ports/">Tailscale VPS security guide</a> explains how Tailscale assigns each authorized device a private <code>100.x.y.z</code> WireGuard address.</p>



<p class="wp-block-paragraph">Instead of opening port <code>18789</code> in UFW or managing Nginx and Certbot manually for an internal dashboard, <a href="https://docs.openclaw.ai/gateway/tailscale" rel="noopener">OpenClaw&#8217;s Tailscale integration</a> pairs two clean layers:</p>



<p class="wp-block-paragraph">• <strong>Loopback Gateway Binding (<code>127.0.0.1:18789</code>):</strong> The OpenClaw Gateway listens only on localhost, so public internet scanners and external VPS interfaces cannot reach it.</p>



<p class="wp-block-paragraph">• <strong>Tailscale Serve Proxy (Port <code>443</code>):</strong> Running on the same VPS, Tailscale provisions a valid TLS certificate for your MagicDNS hostname (such as <code>https://openclaw.your-tailnet.ts.net</code>) and proxies HTTPS requests from your authenticated tailnet devices directly to <code>127.0.0.1:18789</code>.</p>



<figure class="wp-block-image size-full"><img fetchpriority="high" decoding="async" width="1536" height="1024" src="https://blog.aveshost.com/wp-content/uploads/2026/11/openclaw-tailscale-serve-architecture.webp" alt="Architecture diagram showing private OpenClaw access via Tailscale Serve HTTPS proxy to 127.0.0.1:18789" class="wp-image-6136" srcset="https://blog.aveshost.com/wp-content/uploads/2026/11/openclaw-tailscale-serve-architecture.webp 1536w, https://blog.aveshost.com/wp-content/uploads/2026/11/openclaw-tailscale-serve-architecture-300x200.webp 300w, https://blog.aveshost.com/wp-content/uploads/2026/11/openclaw-tailscale-serve-architecture-1024x683.webp 1024w, https://blog.aveshost.com/wp-content/uploads/2026/11/openclaw-tailscale-serve-architecture-768x512.webp 768w" sizes="(max-width: 1536px) 100vw, 1536px" /></figure>



<h2 id="prerequisites-in-tailscale-admin-console" class="wp-block-heading">Prerequisites: MagicDNS, HTTPS Certificates, and Auth Mode</h2>



<p class="wp-block-paragraph">Before configuring OpenClaw, confirm three settings in your Tailscale Admin Console and VPS environment:</p>



<p class="wp-block-paragraph">• <strong>1. Tailscale Logged In on Your VPS &amp; Client:</strong> Install Tailscale on your Ubuntu VPS and connect both the VPS and your laptop/phone to the same tailnet.</p>



<p class="wp-block-paragraph">• <strong>2. Enable MagicDNS &amp; HTTPS Certificates:</strong> In the Tailscale Admin Console under <strong>DNS</strong>, make sure <strong>MagicDNS</strong> is enabled and turn on <strong>HTTPS Certificates</strong> so Tailscale can issue TLS certs for your <code>.ts.net</code> node URL.</p>



<p class="wp-block-paragraph">• <strong>3. Keep OpenClaw Auth Enabled:</strong> Tailscale Serve cannot be paired with <code>gateway.auth.mode: "none"</code>. Configure a strong <code>token</code> or <code>password</code> auth mode, and optionally set <code>allowTailscale: true</code>.</p>



<figure class="wp-block-table"><table class="has-fixed-layout"><thead><tr><th>Tailscale Mode</th><th>Who Can Reach OpenClaw?</th><th>TLS Certificates</th><th>Recommended For</th></tr></thead><tbody><tr><td>serve (Tailnet-Only)</td><td>Only authenticated devices on your private Tailscale network</td><td>Automatic Let&#8217;s Encrypt cert on .ts.net</td><td>Private OpenClaw dashboard &amp; admin control (recommended)</td></tr><tr><td>funnel (Public Internet)</td><td>Anyone on the public internet</td><td>Automatic Let&#8217;s Encrypt cert on .ts.net</td><td>Public webhook endpoints only (avoid for admin UI)</td></tr><tr><td>off + bind: loopback</td><td>Localhost SSH tunnel only</td><td>None (HTTP on 127.0.0.1)</td><td>Single-server SSH port forwarding fallback</td></tr></tbody></table></figure>



<h2 id="step-1-configure-openclaw-for-tailscale-serve" class="wp-block-heading">Step 1: Configure OpenClaw for Loopback + Tailscale Serve</h2>



<p class="wp-block-paragraph">You can configure OpenClaw&#8217;s Tailscale integration either with three CLI commands or directly inside <code>~/.openclaw/openclaw.json</code>. Both approaches keep the Gateway bound strictly to <code>loopback</code> (<code>127.0.0.1:18789</code>) while instructing Tailscale Serve to expose HTTPS privately across your tailnet.</p>



<p class="wp-block-paragraph">Make sure you set <code>gateway.auth.mode</code> to <code>"token"</code> (or <code>"password"</code>) with a long random secret before restarting the Gateway. OpenClaw refuses to start Tailscale Serve if authentication is disabled, ensuring that every session reaching your agent dashboard is backed by both WireGuard transport encryption and Gateway auth.</p>



<p class="wp-block-paragraph">If you prefer manual control over Tailscale without OpenClaw managing the daemon state, you can also run <code>tailscale serve --bg --https=443 http://127.0.0.1:18789</code> directly via the <a href="https://tailscale.com/kb/1312/serve" rel="noopener">Tailscale Serve CLI</a>.</p>



<pre class="wp-block-code"><code># Configure OpenClaw Gateway for loopback + Tailscale Serve
openclaw config set gateway.bind loopback
openclaw config set gateway.tailscale.mode serve
openclaw gateway restart</code></pre>



<pre class="wp-block-code"><code>// ~/.openclaw/openclaw.json
{
  "gateway": {
    "port": 18789,
    "bind": "loopback",
    "auth": {
      "mode": "token",
      "token": "replace-with-long-random-secret",
      "allowTailscale": true
    },
    "tailscale": {
      "mode": "serve"
    }
  }
}</code></pre>



<h2 id="step-2-enable-tailscale-identity-verification" class="wp-block-heading">Step 2: Verify Identity Headers and Connect Over HTTPS</h2>



<p class="wp-block-paragraph">When <code>gateway.auth.allowTailscale</code> is set to <code>true</code>, OpenClaw verifies incoming requests by querying the local Tailscale daemon (<code>tailscale whois</code>) and matching the forwarded identity header (<code>tailscale-user-login</code>). This lets your authorized tailnet devices open the OpenClaw web dashboard smoothly without re-entering tokens on every trusted browser.</p>



<p class="wp-block-paragraph">If you want to restrict which devices on your tailnet can reach the OpenClaw node, combine <code>allowTailscale</code> with tag-based Access Controls in your Tailscale Admin Console—for example, allowing only <code>tag:admin-devices</code> to reach port <code>443</code> on your <code>tag:openclaw</code> server.</p>



<p class="wp-block-paragraph">Open <code>https://your-vps-name.your-tailnet.ts.net</code> in your browser from any device connected to Tailscale. The very first request may pause for a few seconds while Tailscale provisions and caches your node&#8217;s TLS certificate.</p>



<h2 id="step-3-lock-down-ufw-and-verify-no-public-exposure" class="wp-block-heading">Step 3: Verify Zero Public Exposure on Your VPS</h2>



<p class="wp-block-paragraph">After confirming private HTTPS access works over your <code>.ts.net</code> URL, verify that port <code>18789</code> is not exposed publicly in UFW or Docker. Run <code>ss -tulpn | grep 18789</code> to confirm OpenClaw listens strictly on <code>127.0.0.1:18789</code>, and run <code>tailscale serve status</code> to ensure only private Serve (never public Funnel) is active.</p>



<p class="wp-block-paragraph">If you run OpenClaw inside Docker alongside other tools on <a href="https://www.aveshost.com/" rel="noopener">Aveshost</a> self-managed VPS hosting or fully managed VPS hosting, review our <a href="https://blog.aveshost.com/docker-ufw-unexpected-ports/">Docker and UFW port safety guide</a> and monitor uptime privately using <a href="https://blog.aveshost.com/public-website-status-page-with-uptime-kuma/">Uptime Kuma</a>.</p>



<figure class="wp-block-image size-full"><img decoding="async" width="1536" height="1024" src="https://blog.aveshost.com/wp-content/uploads/2026/11/openclaw-tailscale-security-checklist.webp" alt="Six-step security checklist for accessing OpenClaw privately with Tailscale Serve" class="wp-image-6137" srcset="https://blog.aveshost.com/wp-content/uploads/2026/11/openclaw-tailscale-security-checklist.webp 1536w, https://blog.aveshost.com/wp-content/uploads/2026/11/openclaw-tailscale-security-checklist-300x200.webp 300w, https://blog.aveshost.com/wp-content/uploads/2026/11/openclaw-tailscale-security-checklist-1024x683.webp 1024w, https://blog.aveshost.com/wp-content/uploads/2026/11/openclaw-tailscale-security-checklist-768x512.webp 768w" sizes="(max-width: 1536px) 100vw, 1536px" /></figure>



<pre class="wp-block-code"><code># 1. Confirm OpenClaw listens only on 127.0.0.1:18789
ss -tulpn | grep 18789

# 2. Verify Tailscale Serve status (never Funnel for admin UI)
tailscale serve status</code></pre>



<h2 id="faq" class="wp-block-heading">Frequently asked questions</h2>


<div id="rank-math-faq" class="rank-math-block">
<div class="rank-math-list ">
<div id="faq-question-ec07dde72d83483f8a29a8d5967b28c8" class="rank-math-list-item">
<h3 class="rank-math-question ">Is OpenClaw exposed to the public internet when using Tailscale Serve?</h3>
<div class="rank-math-answer ">

<p>No. Tailscale Serve only accepts connections from authenticated devices inside your private Tailscale network (tailnet). Public internet users cannot reach your .ts.net Serve URL or port 18789 when OpenClaw is bound to loopback.</p>

</div>
</div>
<div id="faq-question-2fb34073b9214dcdb3d28d9850783822" class="rank-math-list-item">
<h3 class="rank-math-question ">What is the difference between Tailscale Serve and Tailscale Funnel for OpenClaw?</h3>
<div class="rank-math-answer ">

<p>Tailscale Serve exposes your local service exclusively to devices on your private tailnet, while Tailscale Funnel exposes a service to the public internet. Always use Serve—not Funnel—for your OpenClaw dashboard and Gateway.</p>

</div>
</div>
<div id="faq-question-850f619aed264f45b2c445eeb1b3d998" class="rank-math-list-item">
<h3 class="rank-math-question ">Why does the first HTTPS request to my OpenClaw Tailscale URL take a few seconds?</h3>
<div class="rank-math-answer ">

<p>On the first HTTPS connection after enabling Tailscale Serve, Tailscale automatically provisions and validates a Let&#8217;s Encrypt TLS certificate for your MagicDNS hostname. Subsequent requests load immediately.</p>

</div>
</div>
<div id="faq-question-d1f5c160de714e5d8eec99f6c2ec49d7" class="rank-math-list-item">
<h3 class="rank-math-question ">Can I use Tailscale Serve with OpenClaw gateway.auth.mode set to none?</h3>
<div class="rank-math-answer ">

<p>No. OpenClaw requires authentication (such as token, password, or trusted-proxy) when Tailscale Serve is enabled. Set gateway.auth.mode to token with a strong secret and optionally enable allowTailscale: true.</p>

</div>
</div>
<div id="faq-question-5ba0b3541f424804b7ad465aa951e19e" class="rank-math-list-item">
<h3 class="rank-math-question ">How do I stop exposing OpenClaw via Tailscale Serve?</h3>
<div class="rank-math-answer ">

<p>Run openclaw config set gateway.tailscale.mode off &amp;&amp; openclaw gateway restart, or run tailscale serve off in your VPS terminal if you started Serve manually.</p>

</div>
</div>
</div>
</div>]]></content:encoded>
					
					<wfw:commentRss>https://blog.aveshost.com/access-openclaw-privately-with-tailscale/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>How to Secure VPS Access with Tailscale Without Opening Public Admin Ports</title>
		<link>https://blog.aveshost.com/secure-vps-access-tailscale-without-public-ports/</link>
					<comments>https://blog.aveshost.com/secure-vps-access-tailscale-without-public-ports/#respond</comments>
		
		<dc:creator><![CDATA[James Wilson]]></dc:creator>
		<pubDate>Sat, 21 Nov 2026 20:55:19 +0000</pubDate>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[SSH]]></category>
		<category><![CDATA[Tailscale]]></category>
		<category><![CDATA[Ubuntu VPS]]></category>
		<category><![CDATA[UFW Firewall]]></category>
		<category><![CDATA[VPS Security]]></category>
		<guid isPermaLink="false">https://blog.aveshost.com/?p=6131</guid>

					<description><![CDATA[A step-by-step guide to securing Ubuntu VPS access with Tailscale so SSH, databases, and admin dashboards stay completely unreachable from the public internet while remaining fast for authorized admins.]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">Learning how to <strong>secure VPS access with Tailscale</strong> eliminates one of the biggest attack surfaces on any Linux server: publicly exposed SSH and admin ports. The moment a cloud VPS comes online, automated scanners probe port <code>22</code>, database ports, and container dashboards around the clock.</p>



<p class="wp-block-paragraph">By placing your server on a private WireGuard-encrypted Tailscale mesh network and locking down UFW to accept admin traffic only on the <code>tailscale0</code> interface, your public IP exposes nothing except ports <code>80</code> and <code>443</code> for live web traffic.</p>



<p class="wp-block-paragraph">Whether you run <a href="https://www.aveshost.com/self-managed-vps-hosting" rel="noopener">self-managed VPS hosting</a> or <a href="https://www.aveshost.com/fully-managed-vps-hosting" rel="noopener">fully managed VPS hosting</a> with Aveshost, this guide walks through installing Tailscale, locking down UFW without locking yourself out, enabling identity-based Tailscale SSH, and enforcing tag ACLs.</p>



<div class="wp-block-rank-math-toc-block" id="rank-math-toc"><h2>Table of Contents</h2><nav><div><div><a href="#why-closing-public-admin-ports-matters">Why Closing Public Admin Ports Matters on a VPS</a></div><div><a href="#step-1-install-tailscale-on-ubuntu-vps">Step 1: Install and Authenticate Tailscale on Your Ubuntu VPS</a></div><div><a href="#step-2-lock-down-ufw-to-tailscale0">Step 2: Configure UFW to Allow Admin Traffic Only on tailscale0</a></div><div><a href="#step-3-enable-tailscale-ssh-and-tag-acls">Step 3: Enable Tailscale SSH and Tag-Based ACLs</a></div><div><a href="#vps-emergency-console-and-maintenance">Emergency Console Recovery and Ongoing Maintenance</a></div><div><a href="#faq">Frequently asked questions</a></div></div></nav></div>



<h2 id="why-closing-public-admin-ports-matters" class="wp-block-heading">Why Closing Public Admin Ports Matters on a VPS</h2>



<p class="wp-block-paragraph"><strong>What is Tailscale?</strong> If you are new to private networking, Tailscale is a modern, zero-configuration mesh VPN built on the fast <strong>WireGuard</strong> protocol. Unlike traditional VPNs that force you to manage complex server certificates or route all traffic through a single bottleneck, Tailscale creates an encrypted peer-to-peer private network (called a <em>tailnet</em>) between your laptops, phones, and VPS instances. Every device you authorize receives a private <code>100.x.y.z</code> IP address, letting your devices talk directly over an encrypted tunnel even behind home routers or strict firewalls.</p>



<p class="wp-block-paragraph">Even with SSH key authentication and Fail2Ban enabled, leaving port <code>22</code>, PostgreSQL (<code>5432</code>), MySQL (<code>3306</code>), or web admin panels open on your public IP forces your server to process constant brute-force traffic and zero-day vulnerability scans.</p>



<p class="wp-block-paragraph">With Tailscale, your VPS joins a private overlay network in the <code>100.64.0.0/10</code> range (<code>100.x.y.z</code>). Public scanners hitting your server&#8217;s public IPv4 or IPv6 address see a closed firewall on every administrative port, while your authenticated devices reach SSH and internal dashboards directly over WireGuard.</p>



<figure class="wp-block-table"><table class="has-fixed-layout"><thead><tr><th>Service / Port</th><th>Traditional Public VPS</th><th>Tailscale + UFW Lock-Down</th></tr></thead><tbody><tr><td>SSH (Port 22)</td><td>Exposed to 0.0.0.0/0; constant brute-force bots</td><td>Allowed only on tailscale0 (100.x.y.z)</td></tr><tr><td>Databases (3306 / 5432)</td><td>Risky if bound to public IP or Docker 0.0.0.0</td><td>Bound to 127.0.0.1 or tailscale0 only</td></tr><tr><td>Admin UIs (Portainer / Uptime Kuma)</td><td>Requires public reverse proxy + auth hardening</td><td>Accessible privately over WireGuard tailnet</td></tr><tr><td>Public Websites (80 / 443)</td><td>Open to visitors via eth0</td><td>Open to visitors via eth0 (unchanged)</td></tr></tbody></table></figure>



<figure class="wp-block-image size-full"><img decoding="async" width="1536" height="1024" src="https://blog.aveshost.com/wp-content/uploads/2026/11/tailscale-vps-ufw-architecture.webp" alt="Architecture diagram showing public web ports 80 and 443 separated from private tailscale0 SSH and admin traffic" class="wp-image-6128" srcset="https://blog.aveshost.com/wp-content/uploads/2026/11/tailscale-vps-ufw-architecture.webp 1536w, https://blog.aveshost.com/wp-content/uploads/2026/11/tailscale-vps-ufw-architecture-300x200.webp 300w, https://blog.aveshost.com/wp-content/uploads/2026/11/tailscale-vps-ufw-architecture-1024x683.webp 1024w, https://blog.aveshost.com/wp-content/uploads/2026/11/tailscale-vps-ufw-architecture-768x512.webp 768w" sizes="(max-width: 1536px) 100vw, 1536px" /></figure>



<h2 id="step-1-install-tailscale-on-ubuntu-vps" class="wp-block-heading">Step 1: Install and Authenticate Tailscale on Your Ubuntu VPS</h2>



<p class="wp-block-paragraph">Connect to your VPS over SSH one last time via its public IP, then install the official Tailscale client using the repository script documented in the <a href="https://tailscale.com/kb/1031/install-linux" rel="noopener">Tailscale Linux installation guide</a>.</p>



<p class="wp-block-paragraph">Run <code>sudo tailscale up</code> (or include <code>--ssh</code> to enable identity-based Tailscale SSH right away) and open the printed login URL in your browser to authorize the VPS in your tailnet. Once connected, run <code>tailscale ip -4</code> to note your server&#8217;s private <code>100.x.y.z</code> address.</p>



<p class="wp-block-paragraph"><strong>Critical safety rule:</strong> Before touching any firewall rules, open a brand-new terminal window on your laptop (with Tailscale running locally) and verify you can log in via <code>ssh user@100.x.y.z</code>.</p>



<pre class="wp-block-code"><code># 1. Install Tailscale on Ubuntu VPS
curl -fsSL https://tailscale.com/install.sh | sh

# 2. Authenticate and check your private 100.x IP
sudo tailscale up --ssh
tailscale ip -4</code></pre>



<h2 id="step-2-lock-down-ufw-to-tailscale0" class="wp-block-heading">Step 2: Configure UFW to Allow Admin Traffic Only on tailscale0</h2>



<p class="wp-block-paragraph">Once you confirm your SSH session works over the <code>100.x.y.z</code> Tailscale IP, lock down UFW following the <a href="https://tailscale.com/kb/1077/secure-server-ubuntu" rel="noopener">Tailscale Ubuntu firewall guide</a>. Set default policies to deny all incoming traffic, allow incoming traffic on the <code>tailscale0</code> interface, and keep only public HTTP/HTTPS ports open if the VPS hosts websites.</p>



<p class="wp-block-paragraph">If you previously ran <code>ufw allow 22</code> or <code>ufw allow OpenSSH</code>, inspect <code>sudo ufw status numbered</code> and delete those public port <code>22</code> rules so SSH is no longer reachable from the public internet.</p>



<p class="wp-block-paragraph">Remember: if you run Docker containers on the same VPS, Docker writes its own <code>iptables</code> rules that can bypass UFW when ports are bound to <code>0.0.0.0</code>. Always bind internal admin UIs (such as Portainer, Dokploy, Coolify, or <a href="https://blog.aveshost.com/public-website-status-page-with-uptime-kuma/">Uptime Kuma</a>) to <code>127.0.0.1</code> or your Tailscale IP—see our guide on <a href="https://blog.aveshost.com/docker-ufw-unexpected-ports/">stopping Docker from exposing unexpected ports with UFW</a>.</p>



<pre class="wp-block-code"><code># Test SSH over Tailscale FIRST: ssh youruser@100.x.y.z
sudo ufw default deny incoming
sudo ufw default allow outgoing
sudo ufw allow in on tailscale0
sudo ufw allow 80/tcp
sudo ufw allow 443/tcp

# Remove public port 22 rules if present, then enable
sudo ufw status numbered
sudo ufw enable &amp;&amp; sudo ufw reload</code></pre>



<h2 id="step-3-enable-tailscale-ssh-and-tag-acls" class="wp-block-heading">Step 3: Enable Tailscale SSH and Tag-Based ACLs</h2>



<p class="wp-block-paragraph">To eliminate static SSH key sprawl altogether, enable <strong>Tailscale SSH</strong> with <code>sudo tailscale set --ssh</code>. Tailscale intercepts SSH connections arriving on <code>tailscale0</code> and authenticates users through your identity provider (Google, GitHub, Microsoft, or Okta) and WireGuard node keys.</p>



<p class="wp-block-paragraph">For teams managing multiple servers, assign a server tag such as <code>tag:vps</code> and restrict access in your Tailscale Admin Console <strong>Access Controls</strong> policy so only devices tagged <code>tag:admin-devices</code> can reach port <code>22</code> or internal admin ports. Tailscale ACLs default to deny, meaning any port not explicitly listed in an <code>accept</code> block stays blocked even inside your tailnet.</p>



<p class="wp-block-paragraph">You can also combine Tailscale with private remote desktop tools—for instance, binding self-hosted management dashboards privately alongside our <a href="https://blog.aveshost.com/self-host-rustdesk-ubuntu-vps/">RustDesk Ubuntu VPS setup</a> or securing API backends from our <a href="https://blog.aveshost.com/deploy-fastapi-ubuntu-vps/">Ubuntu FastAPI deployment guide</a>.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="1536" height="1024" src="https://blog.aveshost.com/wp-content/uploads/2026/11/tailscale-vps-hardening-checklist.webp" alt="Six-step checklist for securing Ubuntu VPS access with Tailscale and UFW without public admin ports" class="wp-image-6129" srcset="https://blog.aveshost.com/wp-content/uploads/2026/11/tailscale-vps-hardening-checklist.webp 1536w, https://blog.aveshost.com/wp-content/uploads/2026/11/tailscale-vps-hardening-checklist-300x200.webp 300w, https://blog.aveshost.com/wp-content/uploads/2026/11/tailscale-vps-hardening-checklist-1024x683.webp 1024w, https://blog.aveshost.com/wp-content/uploads/2026/11/tailscale-vps-hardening-checklist-768x512.webp 768w" sizes="(max-width: 1536px) 100vw, 1536px" /></figure>



<pre class="wp-block-code"><code>{
  "tagOwners": {
    "tag:vps": &#91;"autogroup:admin"],
    "tag:admin-devices": &#91;"autogroup:admin"]
  },
  "acls": &#91;
    {
      "action": "accept",
      "src": &#91;"tag:admin-devices"],
      "dst": &#91;"tag:vps:22", "tag:vps:8080", "tag:vps:443"]
    }
  ],
  "ssh": &#91;
    {
      "action": "accept",
      "src": &#91;"tag:admin-devices"],
      "dst": &#91;"tag:vps"],
      "users": &#91;"ubuntu", "root"]
    }
  ]
}</code></pre>



<h2 id="vps-emergency-console-and-maintenance" class="wp-block-heading">Emergency Console Recovery and Ongoing Maintenance</h2>



<p class="wp-block-paragraph">Closing public port <code>22</code> drastically reduces automated attack noise, but always verify you have a working out-of-band recovery path. On <a href="https://www.aveshost.com/" rel="noopener">Aveshost</a> self-managed VPS hosting and fully managed VPS hosting, your client area provides a browser-based VNC/serial console in case <code>tailscaled</code> ever stops during an OS upgrade.</p>



<p class="wp-block-paragraph">Keep <code>tailscale</code> updated alongside regular <code>apt upgrade</code> security patches so WireGuard keys, DERP relay connections, and kernel networking stay healthy.</p>



<h2 id="faq" class="wp-block-heading">Frequently asked questions</h2>


<div id="rank-math-faq" class="rank-math-block">
<div class="rank-math-list ">
<div id="faq-question-200d6bbb1fc1423b97453a7e2d3b2fd1" class="rank-math-list-item">
<h3 class="rank-math-question ">Will I lock myself out of my VPS if I close port 22 in UFW?</h3>
<div class="rank-math-answer ">

<p>Not if you install Tailscale first, verify you can SSH into your VPS via its 100.x.y.z Tailscale IP, and add sudo ufw allow in on tailscale0 before deleting public port 22 rules. You can also use your VPS provider&#8217;s web VNC console as an emergency fallback.</p>

</div>
</div>
<div id="faq-question-24bde45712644863b0ccc4f3a1499581" class="rank-math-list-item">
<h3 class="rank-math-question ">Does Tailscale slow down public website traffic on port 80 or 443?</h3>
<div class="rank-math-answer ">

<p>No. Public visitors continue connecting directly to Nginx, Apache, or Caddy over your VPS&#8217;s normal public network interface (eth0). Only administrative traffic on 100.x.y.z travels through the tailscale0 WireGuard tunnel.</p>

</div>
</div>
<div id="faq-question-908df9de85c149279632594aa8cf3224" class="rank-math-list-item">
<h3 class="rank-math-question ">Why does Docker still expose admin ports even after enabling UFW?</h3>
<div class="rank-math-answer ">

<p>By default, Docker publishes -p 8080:8080 on 0.0.0.0 and inserts iptables rules before UFW&#8217;s chains. To keep admin dashboards private to Tailscale, bind them to 127.0.0.1:8080:8080 or your 100.x.y.z:8080:8080 Tailscale IP.</p>

</div>
</div>
<div id="faq-question-a11303e713d14f1eba93686c97a85ad0" class="rank-math-list-item">
<h3 class="rank-math-question ">What is the difference between regular SSH over Tailscale and Tailscale SSH?</h3>
<div class="rank-math-answer ">

<p>Regular SSH over Tailscale still uses your server&#8217;s sshd daemon and ~/.ssh/authorized_keys file, just routed privately over tailscale0. Tailscale SSH (tailscale set &#8211;ssh) replaces static SSH keys with identity-provider authentication and tailnet ACL rules.</p>

</div>
</div>
<div id="faq-question-724ea356925340febff196fda5c1b209" class="rank-math-list-item">
<h3 class="rank-math-question ">Is Tailscale free for securing a personal or small-team VPS?</h3>
<div class="rank-math-answer ">

<p>Yes. Tailscale&#8217;s Personal plan supports up to 3 users and 100 devices for free, which easily covers securing personal or small-team VPS instances without public admin ports.</p>

</div>
</div>
</div>
</div>]]></content:encoded>
					
					<wfw:commentRss>https://blog.aveshost.com/secure-vps-access-tailscale-without-public-ports/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
