Ntwine

Remote access

Open your board from a phone or another machine.

Ntwine binds 127.0.0.1 and doesn't have a login of its own. To reach the board from a phone or another machine, you put something in front of it to carry the traffic. Ntwine then gates the first visit from every device with a single-use sign-in link.

Set it up

Press R in the terminal running Ntwine, or open Settings → Remote access on that machine, and pick an option:

  Reach this board from anywhere

  ❯ Private name        an unguessable name on ntwine.app — no account, nothing to install
    Cloudflare Tunnel   a domain you own on Cloudflare; cloudflared on this machine
    Tailscale           your tailnet; tailscale serve does the TLS
    Something else      any proxy or tunnel you run — tell Ntwine its address
    Off                 loopback only  (current)

The walkthrough checks what each option needs before it accepts it. It also remembers your answer, so a plain npx ntwine serves it from then on. Off goes back to loopback only.

Ntwine does the authenticating

Whichever option you pick, the board stays on loopback. A tunnel or proxy only adds TLS and a hostname. Every request and every socket has to carry a session, and a device that hasn't redeemed a sign-in link is refused no matter what sits in front.

The readout shows the link as a QR code. Scanning it trades a single-use code for a session cookie, so the link stops working the moment it's used. Press L for a fresh one at any time. You can also run this from another shell, e.g. over SSH on a headless machine:

npx ntwine --link

Sessions are per device:

npx ntwine --sessions          # the devices holding a session
npx ntwine --sign-out <id>     # sign one out
npx ntwine --sign-out all      # or every one

A device can also sign itself out from its own Settings. Signing out any other device only works from the host, so a stolen phone can't sign out your laptop.

Every project at once

There's one Ntwine server per machine, so remote access exposes every project on it, not just the one you launched from.

Staying reachable

While remote access is on and the machine is plugged in, Ntwine keeps it from idle-sleeping, so your board doesn't go dark overnight. Closing the lid or pressing sleep still works.

Try it without touching your board

npx ntwine --sandbox

This starts a second Ntwine that shares nothing with yours: a throwaway home and project on its own port, deleted on CtrlC. Press R in it and walk through any setup. Your credentials come along, so every screen sees what your real board sees.

On this page