orbitdb is a free, open source databases project written in JavaScript and released under MIT. It has 8,808 GitHub stars, 595 forks and 25 open issues, and was last pushed 4 months ago. On this registry it ranks #97 of 203 tracked projects in Databases, with 5 head-to-head comparisons available.

What is orbitdb?

OrbitDB is a serverless, distributed, peer-to-peer database for the decentralized web that stores its data in IPFS and syncs it with peers over Libp2p Pubsub, and it is aimed at developers building decentralized, blockchain, and local-first applications in JavaScript.

What it is

OrbitDB is an eventually consistent database written in JavaScript that runs both in browsers and in Node.js, with support for Linux, OS X, and Windows. It keeps no central server: IPFS provides the data storage and Libp2p Pubsub automatically syncs databases with peers, so every participant holds a replica rather than querying a remote host. Conflict resolution comes from Merkle-CRDTs, the structure formalized in the paper of the same name, which gives the database conflict-free writes and merges. Every database type is implemented on top of the project's own OpLog, an immutable, cryptographically verifiable, operation-based conflict-free replicated data structure for distributed systems. A Go implementation is developed and maintained separately by the Berty project at berty/go-orbit-db.

The concrete thing it replaces is the hosted database sitting behind an application. Where a conventional stack would run a database server in a data centre and have clients call it over the network, OrbitDB moves the database into the application itself, so each peer owns its copy of the data. That is what makes it usable for peer-to-peer and decentralized applications, blockchain applications, and local-first web applications, all of which need to keep reading and writing without a reachable backend. The project lives in the IPFS and Libp2p ecosystem, is licensed MIT, and carries 8,808 stars and 595 forks.

Key capabilities

  • Four built-in database types: events (an immutable, append-only log with traversable history, useful for "latest N" cases or as a message queue), documents (JSON documents indexed by a specified key, useful for search indices or version controlling documents), keyvalue, and keyvalue-indexed (key-value data indexed in a Level key-value database).
  • All data models sit on the OpLog, an immutable, cryptographically verifiable, operation-based CRDT, so writes merge across peers without a coordinating server.
  • Synchronization over Libp2p Pubsub, configured with gossipsub and allowPublishToZeroTopicPeers: true, which is necessary to run a single peer.
  • IPFS, via Helia, as the backing store; databases are opened by name or address and returned addresses take the form /orbitdb/zd....
  • Custom data models: developers can implement and use their own database type by following docs/DATABASES.md#building-a-custom-database, inheriting the same properties as the default models.
  • One JavaScript implementation covering both browsers and Node.js; in the browser it loads from the distributed orbitdb.min.js file, exposing the global OrbitDB namespace.
  • A parallel Go implementation maintained by the Berty project at berty/go-orbit-db.

Who uses it and how

  • Local-first web applications that must stay writable while offline and reconcile changes once peers reconnect.
  • Peer-to-peer and decentralized applications that cannot assume a reachable backend for reads or writes.
  • Blockchain-adjacent projects that need an off-chain, eventually consistent store shared across nodes.
  • Teams that want the same database code running inside a browser tab and inside a Node.js service, from a single JavaScript implementation.
  • Developers who want a fast path can follow the @orbitdb/quickstart module.

Getting started

Install with npm install @orbitdb/core helia, then create a Helia IPFS instance and call createOrbitDB({ ipfs }); opening a database without specifying a type defaults to events. The @orbitdb/quickstart module offers a shorter route to a running instance.

How it compares

No comparable products are named in the facts supplied for this entry, so OrbitDB stands alone in this registry. The only sibling implementation the facts identify is the Go port maintained by the Berty project, which follows the same design for non-JavaScript codebases rather than competing with it.

When to use it — and when not to

A self-hoster operates an IPFS node through Helia and Libp2p pubsub peers rather than a database server, which means less to run but also no managed service, no hosted option, and no vendor support behind it. It is the wrong choice for teams that need strong consistency, multi-statement transactions, or a formal service-level agreement, because OrbitDB is explicitly eventually consistent and resolves conflicts through CRDT merge rather than locking. The project is actively maintained, with a last push on 2026-05-14, an MIT licence, and 25 open issues, so the main caution is architectural rather than a question of abandonment.

project readme (upstream, from github) — read inline

OrbitDB

Matrix npm (scoped) node-current (scoped)

OrbitDB is a serverless, distributed, peer-to-peer database. OrbitDB uses IPFS as its data storage and Libp2p Pubsub to automatically sync databases with peers. It's an eventually consistent database that uses Merkle-CRDTs for conflict-free database writes and merges making OrbitDB an excellent choice for p2p and decentralized apps, blockchain applications and local-first web applications.

OrbitDB provides various types of databases for different data models and use cases:

  • events: an immutable (append-only) log with traversable history. Useful for "latest N" use cases or as a message queue.
  • documents: a document database to which JSON documents can be stored and indexed by a specified key. Useful for building search indices or version controlling documents and data.
  • keyvalue: a key-value database just like your favourite key-value database.
  • keyvalue-indexed: key-value data indexed in a Level key-value database.

All databases are implemented on top of OrbitDB's OpLog, an immutable, cryptographically verifiable, operation-based conflict-free replicated data structure (CRDT) for distributed systems. OpLog is formalized in the paper Merkle-CRDTs. You can also easily extend OrbitDB by implementing and using a custom data model benefitting from the same properties as the default data models provided by the underlying Merkle-CRDTs.

This is the Javascript implementation and it works both in Browsers and Node.js with support for Linux, OS X, and Windows.

A Go implementation is developed and maintained by the Berty project at berty/go-orbit-db.

Installation

Install OrbitDB and its dependencies:

npm install @orbitdb/core helia

Browser ``

Quick Start

If you want to get up and running with OrbitDB quickly, install and follow the instructions in the @orbitdb/quickstart module.

Usage

If you're using @orbitdb/core to develop browser or Node.js applications, use it as a module with the javascript instance of IPFS.

import { createHelia } from 'helia'
import { createOrbitDB } from '@orbitdb/core'
import { gossipsub } from "@chainsafe/libp2p-gossipsub";
import { identify } from "@libp2p/identify";
import { createLibp2p } from 'libp2p'

const Libp2pOptions = {
  services: {
    pubsub: gossipsub({
      // neccessary to run a single peer
      allowPublishToZeroTopicPeers: true
    }),
    identify: identify()
  }
}

;(async function () {
  const libp2p = await createLibp2p({ ...Libp2pOptions })
  const ipfs = await createHelia({libp2p})
  const orbitdb = await createOrbitDB({ ipfs })

  // Create / Open a database. Defaults to db type "events".
  const db = await orbitdb.open("hello")
  
  const address = db.address
  console.log(address)
  // "/orbitdb/zdpuAkstgbTVGHQmMi5TC84auhJ8rL5qoaNEtXo2d5PHXs2To"
  // The above address can be used on another peer to open the same database

  // Listen for updates from peers
  db.events.on("update", async entry => {
    console.log(entry)
    const all = await db.all()
    console.log(all)
  })

  // Add an entry
  const hash = await db.add("world")
  console.log(hash)

  // Query
  for await (const record of db.iterator()) {
    console.log(record)
  }
  
  await db.close()
  await orbitdb.stop()
  await ipfs.stop()
})()

To configure your IPFS instance for persistency and Libp2p to connect to peers, see Creating a Helia instance and the Default Libp2p Configurations in @orbitdb/quickstart for examples.

Documentation

Use the Getting Started guide for an initial introduction to OrbitDB.

You can find more advanced topics in our docs covering:

API

See https://api.orbitdb.org for the full API documentation.

Development

Run Tests

npm run test

Build

npm run build

Benchmark

node benchmarks/orbitdb-events.js

See benchmarks/ for more benchmarks.

API

To build the API documentation, run:

npm run build:docs

Documentation is output to ./docs/api.

Other implementations

If you know of any other repos that ought to be included in this section, please open a PR and add them.

Contributing

Take a look at our organization-wide Contributing Guide. You'll find most of your questions answered there.

If you want to code but don't know where to start, check out the issues labelled "help wanted".

Sponsors

The development of OrbitDB has been sponsored by:

If you want to sponsor developers to work on OrbitDB, please donate to our OrbitDB Open Collective or reach out to @haadcode.

License

MIT © 2015-2023 Protocol Labs Inc., Haja Networks Oy, OrbitDB Community

Frequently asked questions

Is orbitdb free to use?

orbitdb is open source under the MIT licence. There is no licence fee and no seat count — you can self-host it or, where the project offers one, pay a vendor for a managed version instead.

What does orbitdb do?

Peer-to-Peer Databases for the Decentralized Web

What is orbitdb written in?

orbitdb is primarily written in JavaScript. Its source is publicly available at https://github.com/orbitdb/orbitdb, and it has 8,808 GitHub stars.