On Tailscale, machines are distinguishable by a 100.x.y.z IP address, and by a machine name.
The machine name, shown throughout the admin console and the native Tailscale apps, is the canonical name for your machine on your Tailscale network. If you use MagicDNS, the machine name also determines the URL your machine is accessible at.
When a new machine is added to a Tailscale network, we automatically generate its machine name from its OS hostname. The OS hostname is the machine’s operating system name for the device. This field gets reported to Tailscale on startup.
Often, the name ends up being exactly the hostname. But sometimes if a device
already on the network has the same name, the new machine will get a name like
<hostname>-1. If the conflicting machine’s name is later changed, this machine
will still maintain the
<hostname>-1 machine name.
OS hostnames can also have characters that we don’t allow in machine names, so we derive the names following a number of rules that aim to produce sensible results.
|OS Hostname||Machine Name|
|🎊 free form 🎊||free-form|
As corner cases in these rules are found, they will change, so they are not listed here. We enforce unique machine names across a Tailscale network so they may be used as part of the MagicDNS domain name for a machine.
Sometimes the default machine name for a device can be pretty messy and unintuitive,
laptop-a4og4947. Because of this, we’ve added the ability to edit the machine
name for a device from the admin console.
You can edit the machine name via UI in the admin console, or via CLI.
In either the Machines tab of the admin console or the machine details page, click on the icon to the right of the page and select Edit machine name. This will open up the machine name editor.
Once you’ve made your update, you’ll see the new name across the admin console and the Tailscale apps.
In the Tailscale UI, set the machine name as part of
tailscale up --hostname=<name>