---
title: Why AT Protocol?
description: Why Tangled is built on the AT Protocol, and what that buys you over federated or P2P code forges.
---

Code collaboration has one of the strongest network effects in
software: your issues, pull requests, reviews, stars, and
followers all live wherever your code lives. On a centralized
forge, all of that belongs to one company. Leaving means starting
over — new identity, new social graph, and years of collaboration
history left behind.

There are several models for decentralized code collaboration
platforms, ranging from ActivityPub's (Forgejo) federated model,
to Radicle's entirely P2P model. Each solves part of the problem:

- **Federation** distributes hosting, but your identity is bound
  to your instance. If your instance shuts down or defederates,
  you lose your account, and cross-instance collaboration is only
  as good as the bridges between servers.
- **P2P** gives you full sovereignty, but pushes a lot of
  complexity onto every user — key management, discovery, and
  availability become your problem.

Our approach attempts to be the best of both worlds by adopting
the [AT Protocol](https://atproto.com) — a protocol for building
decentralized social applications with a **central identity**.

## Identity that survives everything

On the AT Protocol, your identity is a
[DID](https://atproto.com/specs/did) — a stable identifier that is
independent of any server, fronted by a human-readable handle
(usually a domain name you control). Your account lives on a
Personal Data Server (PDS) of your choosing, and you can move
between PDSes without changing who you are. Nothing on Tangled
breaks when you do: your repositories, issues, and followers all
reference your DID, not your server.

You can think of it as "one account for all of the atmosphere":
the same account you use on Bluesky or any other AT Protocol
application signs you into Tangled. We believe AT Protocol has
greatly simplified one of the hardest parts of social software —
having your friends already on it.

## Your data, as records you own

Everything social on Tangled — issues, pull requests, comments,
stars, follows, profile — is stored as records under `sh.tangled.*`
[lexicons](https://atproto.com/guides/lexicon) in *your* AT
Protocol repository, on *your* PDS. Tangled reads them; it doesn't
own them.

This has practical consequences:

- Any application can read (and build on) the same records — the
  appview at [tangled.org](https://tangled.org) is one view of the
  network, [Bobbin](/reference/bobbin/) is another, and anyone can
  build their own from the firehose.
- Deleting or migrating your account takes your collaboration
  history with you.
- There is no privileged write path: Tangled writes records to
  your PDS like any other client would.

Git data itself is the one exception — repositories are too large
and too specialized to live in a PDS, so they live on
[knots](/knots/), which you can also self-host. Each repository
gets its own DID too, making it stable across renames and
transfers.

## Services that don't need to trust each other

Tangled is composed of small, independently hostable services:
knots host git, [spindles](/spindles/) run CI, and the appview
ties the network together. They authenticate to each other with AT
Protocol [service
auth](https://atproto.com/specs/xrpc#inter-service-authentication-jwt):
requests are signed with the user's DID key and verified against
their public DID document. No shared secrets, no API tokens to
provision — any knot can trust a request from any appview, and
vice versa, because identity is cryptographic and global.

## The tenets

Tangled's design goals, which the AT Protocol lets us hit all at
once:

1. **Ownership of data** — your identity and social data are
   yours, portable across servers and applications.
2. **Low barrier to entry** — sign up in seconds on
   [tangled.org](https://tangled.org/signup), or bring an existing
   AT Protocol account. Self-hosting is optional, never required.
3. **No compromise on user-experience** — the appview gives the
   whole decentralized network the coherence of a single site.

## Further reading

- [Introducing Tangled](https://blog.tangled.org/intro) — the
  announcement post
- [What are knots?](/knots/) and [what are spindles?](/spindles/)
- [AT Protocol documentation](https://atproto.com/docs)
