When two devices cannot reach each other directly, Tailscale relays the traffic through its DERP servers, which can be slow. Peer relays let one of your own nodes do that job instead.
On a machine with a good connection and a UDP port that is reachable, pick a port:
sudo tailscale set --relay-server-port=40000
Then allow devices to use it with a grant in the policy file. The capability takes no parameters:
"grants": [
{
"src": ["autogroup:member"],
"dst": ["tag:relay"],
"app": { "tailscale.com/cap/relay": [] }
}
]
Here the relay carries tag:relay. Devices that use it need Tailscale 1.86 or newer, and they must be able to reach that UDP port, so open it in the firewall and forward it on your router if the relay sits at home.
tailscale ping to a peer shows whether traffic now goes through your relay instead of DERP. If no peer relay is available, Tailscale falls back to DERP, so nothing breaks when the relay is down.
To stop relaying, set the port to an empty value with --relay-server-port=. I would pick a box with stable uptime for this, since a relay that reboots often just adds hiccups.
Further reading: Tailscale Peer Relays
Going deeper: Why a Tailscale device vanishes after 180 days, and how to stop it