iroh

PlatformArchitectures
macOSarm64
Linuxx86_64, aarch64 (glibc and musl), armv7
Windowsx86_64, aarch64
Androidaarch64, armv7

All platforms require Node.js 20.3.0 or newer.

The JavaScript bindings to iroh are published on npm as @number0/iroh and shipped from iroh-ffi. They’re built with napi-rs, so the package distributes prebuilt native binaries. No Rust toolchain or local compilation is needed.

Install

Requires Node.js 20.3.0 or newer. Prebuilt N-API binaries are published for:

  • macOS: arm64 (no Intel build)
  • Linux: x86_64 and aarch64 (glibc + musl), armv7 (gnueabihf + musleabihf)
  • Windows: x86_64 and aarch64
  • Android: aarch64 and armv7

Hello, iroh

Endpoint.bind applies the n0 preset (public discovery + default relays) by default. Pass an EndpointOptions object to override the preset, supply a fixed secret key, or set ALPNs.

A two-peer echo

A minimal sender/receiver pair over a bidirectional stream:

Start the receiver in one terminal, copy the printed ticket, and run the sender with it in another.

Next steps

Read the original on docs.iroh.computer ↗