> Every Taji docs page as Markdown: https://docs.taji.is/llms.txt

# Tailscale

Remote Control: Taji on your phone, from anywhere, opened with Face ID. Nothing is installed on the phone: it reaches the Taji running on this device through Tailscale Funnel.

## Before you link

You need a free Tailscale account (signing in with Google, Apple, Microsoft or GitHub makes one; Tailscale's [pricing page](https://tailscale.com/pricing) ticks Funnel on every plan, the free Personal plan included), a phone with Face ID, Touch ID or a passcode, and this device awake with Taji open. The phone needs iOS 18.4, Chrome 129 or Firefox 119, or later. Tailscale's Funnel relays carry the traffic and cannot read it: TLS ends on this device. Funnel lists your address, `https://taji.<your tailnet>.ts.net`, in a public certificate log, and only a phone you pair gets past its door.

## Link

The form is `tailscale`. Start it from Remote Control, the Vault card's second row on the Connections page, from a terminal with `taji-link remote`, or ask your agent to (`ui_open` with `form: "tailscale"`). Its steps and the words it refuses with are the plugin's manifest, `taji-plugin.toml`; the last step, pairing your phone by its QR, is Taji's own. The address step took from 6 s to over five minutes (measured 2026-11-22); Taji gives up at ten. Once linked, the switch serves at once, and off stops serving while keeping the sign-in and your phones.

## Use

1. **Pair a phone.** Scan the QR with its camera. The page asks "Pair this phone with Taji?" over a name for the phone; press Pair, and the phone saves a passkey behind its Face ID, fingerprint or passcode. Without the camera, open your address on the phone, press Pair a new phone, and type the code shown under Pair your phone. Pair another with Pair a phone in the row's ••• menu.
2. **Open Taji.** Your address opens on Unlock, whichever browser holds it: the passkey, not the browser, is the pairing. Each open is Face ID, and so is an approval, a link or the vault more than five minutes after the last. The phone offers once to add Taji to its Home Screen.
3. **Work from the phone.** It does all the window does, orders and approvals included. The bar holds Desk (your layout's panes, one at a time), Positions, your agent's orb, Chats and More. On a chart one finger pans, two pinch, a long press opens the right-click menu, and Expand fills the screen. An installed plugin's pane runs in the phone's browser, which cannot keep it off the internet as Taji's window does. It links typed keys and opens the vault by backup password; a browser sign-in, and pairing another phone, finish on this device.
4. **Manage your phones.** The ••• menu lists each phone and, under it, its sessions, each with where and when it was last seen. Sign out ends one session. Forget signs the phone out everywhere, and its passkey opens Taji no more. A passkey synced by iCloud Keychain or Google Password Manager opens Taji on every device of that account, so Forget names it as shared.
5. **Stop.** The switch turns Remote Control off, once Taji's Tailscale node has closed, within 10 s. Sign out of Tailscale, in the ••• menu, keeps your phones' passkeys for the same address.

While this device sleeps or Taji is closed, the phone shows Taji's own "Can't reach Taji" page; a Safari tab that has not opened Taji in seven days of Safari use shows Safari's error instead ([WebKit](https://webkit.org/blog/10218/full-third-party-cookie-blocking-and-more/)). While Remote Control is on, Taji keeps a Mac on power from sleeping while idle. Restarting Taji asks each phone for Face ID once. Tailscale signs Taji out after 180 days unless you turn off key expiry for `taji`: the setup's last screen opens that page, and from 14 days ahead the row warns and Turn off key expiry is in the ••• menu.

## Behaviour and limits

A paired phone is the window over the internet, through a door apart from the loopback wire (`engine/crates/taji/src/wire/remote.rs`):

- **Second listener.** Linked, the kernel binds a second loopback port for `taji-tailscale`'s Funnel traffic. TLS ends in the sidecar, which uploads no log to Tailscale (its relays cannot read traffic; the public name is in the certificate log). The door refuses the loopback wire's `local`, `agent`, `page` and `sheet` tokens (`no_local_agent_or_sheet_token_is_heard_remotely`), and minting a pairing code, by hand at the window, with 403 `hand`.
- **Tokenless list.** Tokenless, it serves only page files, `/app/frame/kit.css`, symbol logos (anyone can trigger a `logos.taji.is` fetch), `/app/pair`, `remote/challenge`, `remote/pair*`, `POST /app/token` and `/ws/*` upgrades (first message: the token, within 5 s); other paths get an empty 404, a bad token 401 before its body is read (`the_phones_door_hears_its_tokenless_list_alone`).
- **Passkey.** WebAuthn via `webauthn-rs`, user-verified; passkeys live in `<state dir>/remote.json` (`0600`); the phone stores no cookie or token.
- **Device token.** Sign-in mints one in memory (`page` + `sheet` scopes, this door only), by hand for five minutes, then 401 `passkey` until Face ID re-verifies; it expires in a day, closing its sockets; a step-up token revokes its predecessor on first use; Forget or Sign out revokes tokens and sockets at once (`a_by_hand_act_past_five_minutes_asks_the_passkey`, `a_device_token_lapses_in_a_day`). The phone's page draws sheet forms itself; Touch ID, browser sign-in and pairing stay at the device.
- **Frame key.** A 64-hex per-session key, minted with the device token and kept across step-ups, opens `GET /plugin/<id>/{frame,ui/<file>,mark}` as a query parameter, never a header, until the session ends; the frame can read it (`a_frame_key_lives_and_dies_with_its_session`, `the_phones_door_frames_a_plugin_under_its_sessions_key_alone`).
- **Sidecar caps.** Go's `net/http` faces the internet: 30 tokenless `POST`s a minute per source (IPv4 or IPv6 /48), 16 in-flight forwards per source and 256 total (tokened/keyed and tokenless pooled apart), 30 s body read, 120 s response write, duplicate `x-taji-token` refused (`plugins/tailscale/sidecar/main_test.go`).

## Unlink

Choose **Sign out of Tailscale** in Remote Control's ••• menu on the Connections page (or `POST /verb/remote/unlink`). Taji stops serving Funnel, signs the `taji` node out of Tailscale, and deletes `<state dir>/tailscale/`. Paired phones' passkeys stay in `<state dir>/remote.json` for the same address; use **Forget** in the ••• menu to remove a phone too.

Confirm the `taji` machine is removed from **Machines** in the [Tailscale admin console](https://login.tailscale.com/admin/machines), and delete it there if it remains.

## If it fails

| Symptom | Cause | Fix |
|---|---|---|
| The address step waits past ten minutes (`unanswered`) | The public name is not answering yet, or the network blocks Cloudflare's DNS over HTTPS (`https://cloudflare-dns.com/dns-query`) | Check again, which restarts the ten minutes; on a network that blocks it, it never passes. Once linked, the check no longer turns Remote Control off |
| Remote Control reads Reconnecting | Its sidecar stopped, or the public name missed three checks a minute apart (a node could lose Funnel with its status green until Tailscale fixed issue 21114 on its servers on 2026-11-02; the check stays for a recurrence), so Taji starts the sidecar again | Nothing: it turns back on by itself; why is in `sidecar.log.1` |
| Remote Control is off after a failure | Tailscale signed Taji out or refused it; a sidecar that exits is restarted, its wait doubling from 1 s to a minute, and starting over once one has served ten minutes | Sign in again, or ask your admin, as it says; the last two sidecars' logs are `sidecar.log` and `sidecar.log.1` in Taji's `tailscale` state folder |
| No paired phone opens Taji | A passkey belongs to its address: the machine or tailnet was renamed, or a fresh Taji joined as `taji-1` | Pair each phone again |

## References

- [How the integration works, and why](https://docs.taji.is/catalog/tailscale/architecture.md)
- [Taji's security model](https://docs.taji.is/architecture/security.md)
- [Tailscale Funnel](https://tailscale.com/kb/1223/funnel), [tsnet](https://tailscale.com/kb/1244/tsnet), [HTTPS certificates](https://tailscale.com/kb/1153/enabling-https), [key expiry](https://tailscale.com/kb/1028/key-expiry)
- `plugins/tailscale/taji-plugin.toml`, `plugins/tailscale/src/lib.rs` (the arm), `plugins/tailscale/sidecar/main.go` (the sidecar; its header is the protocol)
