# getumbrel/umbrel architecture

> Architecture diagram of the GitHub repository getumbrel/umbrel, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-11). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/getumbrel/umbrel
- Repository: https://github.com/getumbrel/umbrel

## Overview

umbrelOS is a self-hosted home-server operating system, with web UI and companion clients for managing a device and its services. Its major capabilities include accounts and app sharing, app discovery and installation, files and storage management, Photos, virtual machines, backups, and AI-agent access. The graph emphasizes the documented product surface and sampled server/API relationships; several UI and service internals are unsampled, so their connections are omitted rather than inferred.

Main entry points: [`packages/umbreld/source/index.ts`](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/index.ts) (umbrelOS), [`packages/umbreld/source/modules/server/trpc/trpc.ts`](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/server/trpc/trpc.ts) (TRPC server), [`packages/umbreld/source/modules/photos/routes.ts`](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/photos/routes.ts) (Photos routes), [`packages/umbreld/source/modules/user/routes.ts`](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/user/routes.ts) (User routes)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_experience["User experience"]
  node_web["Dashboard UI<br/>[dashboard.tsx]"]
  node_mobile["Mobile clients<br/>[RootView.kt]"]
  node_mac["Mac client<br/>[AppState.swift]"]
end

subgraph group_platform["OS platform"]
  node_os["umbrelOS<br/>[index.ts]"]
  node_accounts["Accounts and auth<br/>[auth.ts]"]
  node_userapi["User routes<br/>[routes.ts]"]
  node_api["TRPC server<br/>[trpc.ts]"]
end

subgraph group_storage["Files and storage"]
  node_files["Files service<br/>[files.ts]"]
  node_fileindex[("File index")]
  node_external["External storage"]
  node_network["Network storage<br/>[network-storage.ts]"]
  node_storageui["Storage manager<br/>[use-storage.ts]"]
  node_hardware["Hardware storage"]
  node_raid["RAID manager<br/>[raid.ts]"]
end

subgraph group_services["Server capabilities"]
  node_appstore["App store<br/>[index.tsx]"]
  node_appsapi["App routes<br/>[routes.ts]"]
  node_photosapi["Photos service<br/>[photos.ts]"]
  node_photoroutes["Photos routes<br/>[routes.ts]"]
  node_machines["Virtual machines<br/>[routes.ts]"]
  node_backups["Backups<br/>[routes.ts]"]
  node_mcp["MCP server<br/>[routes.ts]"]
end

node_operator(("Household user"))

node_operator -->|"uses"| node_os
node_os -->|"initializes"| node_accounts
node_os -->|"initializes"| node_files
node_os -->|"initializes"| node_appsapi
node_os -->|"initializes"| node_userapi
node_userapi -->|"uses"| node_accounts
node_web -.->|"accesses"| node_api
node_mobile -.->|"connects"| node_os
node_mac -.->|"connects"| node_os
node_appsapi -->|"registers routes"| node_api
node_photoroutes -->|"registers routes"| node_api
node_photoroutes -->|"calls"| node_photosapi
node_storageui -->|"queries"| node_api
node_hardware -->|"uses sizing"| node_raid
node_fileindex -.->|"supports indexing"| node_files
node_operator -->|"discovers apps"| node_appstore
node_operator -->|"manages storage"| node_storageui
node_operator -->|"views photos"| node_photosapi
node_operator -->|"runs machines"| node_machines
node_operator -->|"backs up data"| node_backups
node_operator -->|"connects agents"| node_mcp
node_operator -->|"uses drives"| node_external
node_operator -->|"uses shares"| node_network

click node_os "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/index.ts"
click node_web "https://github.com/getumbrel/umbrel/blob/master/packages/ui/src/dashboard.tsx"
click node_mobile "https://github.com/getumbrel/umbrel/blob/master/clients/android/app/src/main/kotlin/com/umbrel/android/RootView.kt"
click node_mac "https://github.com/getumbrel/umbrel/blob/master/clients/apple/macos/Sources/Umbrel/AppState.swift"
click node_accounts "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/auth/auth.ts"
click node_userapi "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/user/routes.ts"
click node_api "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/server/trpc/trpc.ts"
click node_appstore "https://github.com/getumbrel/umbrel/blob/master/packages/ui/src/features/app-store/index.tsx"
click node_appsapi "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/apps/routes.ts"
click node_files "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/files/files.ts"
click node_fileindex "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/files/file-index-engine.ts"
click node_external "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/files/external-storage.ts"
click node_network "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/files/network-storage.ts"
click node_storageui "https://github.com/getumbrel/umbrel/blob/master/packages/ui/src/features/storage/hooks/use-storage.ts"
click node_hardware "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/hardware/internal-storage.ts"
click node_raid "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/hardware/raid.ts"
click node_photosapi "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/photos/photos.ts"
click node_photoroutes "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/photos/routes.ts"
click node_machines "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/machines/routes.ts"
click node_backups "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/backups/routes.ts"
click node_mcp "https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/mcp/routes.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_web,node_mobile,node_mac,node_operator toneBlue
class node_os,node_accounts,node_userapi,node_api toneAmber
class node_files,node_fileindex,node_external,node_network,node_storageui,node_hardware,node_raid toneMint
class node_appstore,node_appsapi,node_photosapi,node_photoroutes,node_machines,node_backups,node_mcp toneRose
```

## Components

### User experience

- [Dashboard UI](https://github.com/getumbrel/umbrel/blob/master/packages/ui/src/dashboard.tsx): `packages/ui/src/dashboard.tsx`
- [Mobile clients](https://github.com/getumbrel/umbrel/blob/master/clients/android/app/src/main/kotlin/com/umbrel/android/RootView.kt): `clients/android/app/src/main/kotlin/com/umbrel/android/RootView.kt`
- [Mac client](https://github.com/getumbrel/umbrel/blob/master/clients/apple/macos/Sources/Umbrel/AppState.swift): `clients/apple/macos/Sources/Umbrel/AppState.swift`

### OS platform

- [umbrelOS](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/index.ts): `packages/umbreld/source/index.ts`
- [Accounts and auth](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/auth/auth.ts): `packages/umbreld/source/modules/auth/auth.ts`
- [User routes](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/user/routes.ts): `packages/umbreld/source/modules/user/routes.ts`
- [TRPC server](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/server/trpc/trpc.ts): `packages/umbreld/source/modules/server/trpc/trpc.ts`

### Files and storage

- [Files service](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/files/files.ts): `packages/umbreld/source/modules/files/files.ts`
- [File index](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/files/file-index-engine.ts): `packages/umbreld/source/modules/files/file-index-engine.ts`
- [External storage](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/files/external-storage.ts): `packages/umbreld/source/modules/files/external-storage.ts`
- [Network storage](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/files/network-storage.ts): `packages/umbreld/source/modules/files/network-storage.ts`
- [Storage manager](https://github.com/getumbrel/umbrel/blob/master/packages/ui/src/features/storage/hooks/use-storage.ts): `packages/ui/src/features/storage/hooks/use-storage.ts`
- [Hardware storage](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/hardware/internal-storage.ts): `packages/umbreld/source/modules/hardware/internal-storage.ts`
- [RAID manager](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/hardware/raid.ts): `packages/umbreld/source/modules/hardware/raid.ts`

### Server capabilities

- [App store](https://github.com/getumbrel/umbrel/blob/master/packages/ui/src/features/app-store/index.tsx): `packages/ui/src/features/app-store/index.tsx`
- [App routes](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/apps/routes.ts): `packages/umbreld/source/modules/apps/routes.ts`
- [Photos service](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/photos/photos.ts): `packages/umbreld/source/modules/photos/photos.ts`
- [Photos routes](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/photos/routes.ts): `packages/umbreld/source/modules/photos/routes.ts`
- [Virtual machines](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/machines/routes.ts): `packages/umbreld/source/modules/machines/routes.ts`
- [Backups](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/backups/routes.ts): `packages/umbreld/source/modules/backups/routes.ts`
- [MCP server](https://github.com/getumbrel/umbrel/blob/master/packages/umbreld/source/modules/mcp/routes.ts): `packages/umbreld/source/modules/mcp/routes.ts`

### Other components

- **Household user**

## Connections

- Household user → umbrelOS: uses (evidence: `README.md`)
- umbrelOS → Accounts and auth: initializes (evidence: `packages/umbreld/source/index.ts`)
- umbrelOS → Files service: initializes (evidence: `packages/umbreld/source/index.ts`)
- umbrelOS → App routes: initializes (evidence: `packages/umbreld/source/index.ts`)
- umbrelOS → User routes: initializes (evidence: `packages/umbreld/source/index.ts`)
- User routes → Accounts and auth: uses (evidence: `packages/umbreld/source/modules/user/routes.ts`)
- Dashboard UI → TRPC server: accesses
- Mobile clients → umbrelOS: connects
- Mac client → umbrelOS: connects
- App routes → TRPC server: registers routes (evidence: `packages/umbreld/source/modules/apps/routes.ts`)
- Photos routes → TRPC server: registers routes (evidence: `packages/umbreld/source/modules/photos/routes.ts`)
- Photos routes → Photos service: calls (evidence: `packages/umbreld/source/modules/photos/routes.ts`)
- Storage manager → TRPC server: queries (evidence: `packages/ui/src/features/storage/hooks/use-storage.ts`)
- Hardware storage → RAID manager: uses sizing (evidence: `packages/umbreld/source/modules/hardware/internal-storage.ts`)
- File index → Files service: supports indexing
- Household user → App store: discovers apps (evidence: `README.md`)
- Household user → Storage manager: manages storage (evidence: `README.md`)
- Household user → Photos service: views photos (evidence: `README.md`)
- Household user → Virtual machines: runs machines (evidence: `README.md`)
- Household user → Backups: backs up data (evidence: `README.md`)
- Household user → MCP server: connects agents (evidence: `README.md`)
- Household user → External storage: uses drives (evidence: `README.md`)
- Household user → Network storage: uses shares (evidence: `README.md`)
