whatisgithub

What is iroh?

n0-computer/iroh — explained in plain English

Analysis updated 2026-06-24

8,533RustAudience · developerComplexity · 4/5LicenseSetup · moderate

In one sentence

Iroh is a Rust library for connecting devices directly by public key instead of IP address, enabling reliable peer-to-peer connections through firewalls with automatic fallback to relay servers.

Mindmap

mindmap
  root((iroh))
    Core concept
      Connect by public key
      Not by IP address
    Connection methods
      Hole-punching
      Relay fallback
      QUIC transport
    Components
      iroh-blobs
      iroh-gossip
      iroh-docs
    Audience
      Rust developers
      P2P app builders
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Build a peer-to-peer file transfer app that works through home routers and firewalls without requiring port forwarding.

USE CASE 2

Create a real-time sync service between devices that automatically reconnects when they change networks or get new IP addresses.

USE CASE 3

Implement a gossip messaging network where messages spread across many devices even on phones with limited resources.

USE CASE 4

Transfer large files between two devices with verified integrity using iroh-blobs.

What is it built with?

RustQUIC

How does it compare?

n0-computer/irohvi/websocatgyroflow/gyroflow
Stars8,5338,5038,480
LanguageRustRustRust
Setup difficultymoderateeasyeasy
Complexity4/52/52/5
Audiencedeveloperdevelopergeneral

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · moderate Time to first run · 30min

Rust required, bindings for non-Rust languages are in a separate repository.

Use freely for any purpose including commercial, under either the MIT or Apache 2.0 license, your choice.

So what is it?

Iroh is a Rust networking library built around one idea: instead of connecting to a device by its IP address, you connect to it by a public key. IP addresses change when devices move between networks, get reassigned by internet providers, or sit behind firewalls and routers. A public key stays with a device permanently, so iroh can always find and maintain the fastest connection regardless of where the device actually is at that moment. To make a direct connection work between two devices that are both behind home routers or corporate firewalls, iroh uses a technique called hole-punching. Without going into networking detail, this is a method of tricking two firewalls into letting traffic through between devices that neither firewall would normally allow to connect directly. If hole-punching fails, iroh falls back to an open network of public relay servers. The project measures connection performance continuously and publishes those results publicly. The transport layer is QUIC, a modern protocol originally developed by Google and now an internet standard. QUIC provides encrypted connections, lets multiple streams of data travel over one connection without one slow stream blocking the others, and supports sending small packets of data alongside the main streams. On top of the core connection library, the project offers several companion components. Iroh-blobs handles transferring files of any size, from kilobytes to terabytes, using a specific hashing format for verified transfers. Iroh-gossip sets up publish-subscribe networks where messages spread across many participants, designed to work even on phones with limited resources. Iroh-docs provides a simple key-value store that eventually becomes consistent across devices. Iroh is primarily a Rust library, but a separate repository provides bindings so it can be used from other programming languages. The project is dual-licensed under MIT and Apache 2.0.

Copy-paste prompts

Prompt 1
Using the iroh Rust library, write code to establish a direct QUIC connection between two peers identified only by their public keys.
Prompt 2
Show me how to use iroh-blobs to send a large file from one device to another with hash-verified transfer and progress reporting.
Prompt 3
How do I set up iroh-gossip so multiple devices subscribe to a shared topic and receive messages even when behind different firewalls?
Prompt 4
Write a Rust example using iroh that opens multiple independent data streams over one connection without streams blocking each other.

Frequently asked questions

What is iroh?

Iroh is a Rust library for connecting devices directly by public key instead of IP address, enabling reliable peer-to-peer connections through firewalls with automatic fallback to relay servers.

What language is iroh written in?

Mainly Rust. The stack also includes Rust, QUIC.

What license does iroh use?

Use freely for any purpose including commercial, under either the MIT or Apache 2.0 license, your choice.

How hard is iroh to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is iroh for?

Mainly developer.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.