HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
dgraph-io
badger
Go2017–2022
dgraph-io / badger

badger

Fast key-value DB in Go.

25Distinct people
30Mentions
0Explicit recommenders
15.8KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

Fast key-value DB in Go.

GitHub

Where it is used

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

No other repository is repeatedly linked in the same discussions.

This week on Hacker News

Nov 8–Nov 15 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/15/2026, 12:03:30 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year30 dated mentions

Observed mentions: 2017-05-14 17:08:41 UTC to 2022-08-23 23:52:42 UTC.

02468102017-01-01 00:00:00 UTC to 2018-01-01 00:00:00 UTC (exclusive): 3 mentions; 1 submissions, 2 comments20172018-01-01 00:00:00 UTC to 2019-01-01 00:00:00 UTC (exclusive): 10 mentions; 1 submissions, 9 comments2019-01-01 00:00:00 UTC to 2020-01-01 00:00:00 UTC (exclusive): 4 mentions; 1 submissions, 3 comments20192020-01-01 00:00:00 UTC to 2021-01-01 00:00:00 UTC (exclusive): 4 mentions; 0 submissions, 4 comments2021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments2022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 7 mentions; 0 submissions, 7 comments2022

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20172017-01-01 00:00:00 UTC2018-01-01 00:00:00 UTC312
20182018-01-01 00:00:00 UTC2019-01-01 00:00:00 UTC1019
20192019-01-01 00:00:00 UTC2020-01-01 00:00:00 UTC413
20202020-01-01 00:00:00 UTC2021-01-01 00:00:00 UTC404
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC202
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC707

From the project README

An excerpt from the repository, fetched Nov 13, 2026.

Read the project’s introduction
BadgerDB BadgerDB is an embeddable, persistent and fast key-value (KV) database written in pure Go. It is the underlying database for Dgraph, a fast, distributed graph database. It's meant to be a performant alternative to non-Go-based key-value stores like RocksDB. Project Status Badger is stable and is being used to serve data sets worth hundreds of terabytes. Badger supports concurrent ACID transactions with serializable snapshot isolation (SSI) guarantees. A Jepsen-style bank test runs nightly for 8h, with --race flag and ensures the maintenance of transactional guarantees. Badger has also been tested to work with filesystem level anomalies, to ensure persistence and consistency. Badger is being used by a number of projects which includes Dgraph, Jaeger Tracing, UsenetExpress, and many more. The list of projects using Badger can be found here. Please consult the Changelog for more detailed information on releases. Note: Badger is built with go 1.23 and we refrain from bumping this version to minimize downstream effects of those using Badger in applications built with older versions of Go. Table of Contents BadgerDB Project Status Table of Contents Getting Started Installing Installing Badger Command Line Tool Choosing a version Badger Documentation Resources Blog Posts Design Comparisons Benchmarks Projects Using Badger Contributing Contact Getting Started Installing To start using Badger, install Go 1.23 or above. Badger v3 and above needs go modules. From your project, run the following command go get github.com/dgraph-io/badger/v4 This will retrieve the library. Installing Badger Command Line Tool Badger provides a CLI tool which can perform certain operations like offline backup/restore. To install the Badger CLI, retrieve the repository and checkout the desired version. Then run cd badger go install . This will install the badger command line utility into your $GOBIN path. Badger Documentation Badger Documentation is available at https://badger.dgraph.io Resources Blog Posts Introducing Badger: A fast key-value store written natively in Go Make Badger crash resilient with ALICE Badger vs LMDB vs BoltDB: Benchmarking key-value databases in Go Concurrent ACID Transactions in Badger Design Badger was written with these design goals in mind: Write a key-value database in pure Go. Use latest research to build the fastest KV database for data sets spanning terabytes. Optimize for SSDs. Badger’s design is based on a paper titled WiscKey: Separating Keys from Values in SSD-conscious Storage. Comparisons Feature Badger RocksDB BoltDB Design LSM tree with value log LSM tree only B+ tree High Read throughput Yes No Yes High Write throughput Yes Yes No Designed for SSDs Yes (with latest research 1) Not specifically 2 No Embeddable Yes Yes Yes Sorted KV access Yes Yes Yes Pure Go (no Cgo) Yes No Yes Transactions Yes, ACID, concurrent with SSI3 Yes (but non-ACID) Yes, ACID Snapshots Yes Yes Yes TTL support Yes Yes No 3D access (key-value-version) Yes4 No No 1 The WISCKEY paper (on which Badger is based) saw big wins with separating values from keys, significantly reducing the write amplification compared to a typical LSM tree. 2 RocksDB is an SSD optimized version of LevelDB, which was designed specifically for rotating disks. As such RocksDB's design isn't aimed at SSDs. 3 SSI: Serializable Snapshot Isolation. For more details, see the blog post Concurrent ACID Transactions in Badger 4 Badger provides direct access to value versions via its Iterator API. Users can also specify how many versions to keep per key via Options. Benchmarks We have run comprehensive benchmarks against RocksDB, Bolt and LMDB. The benchmarking code, and the detailed logs for the benchmarks can be found in the badger-bench repo. More explanation, including graphs can be found the blog posts (linked above). Projects Using Badger Below is a list of known projects that use Badger: Dgraph - Distributed graph database. Jaeger - Distributed tracing platform. go-ipfs - Go client for the InterPlanetary File System (IPFS), a new hypermedia distribution protocol. Riot - An open-source, distributed search engine. emitter - Scalable, low latency, distributed pub/sub broker with message storage, uses MQTT, gossip and badger. OctoSQL - Query tool that allows you to join, analyse and transform data from multiple databases using SQL. Dkron - Distributed, fault tolerant job scheduling system. smallstep/certificates - Step-ca is an online certificate authority for secure, automated certificate management. Sandglass - distributed, horizontally scalable, persistent, time sorted message queue. TalariaDB - Grab's Distributed, low latency time-series database. Sloop - Salesforce's Kubernetes History Visualization Project. Usenet Express - Serving over 300TB of data with Badger. gorush - A push notification server written in Go. 0-stor - Single device object store. Dispatch Protocol - Blockchain protocol for distributed application data analytics. GarageMQ - AMQP server written in Go. RedixDB - A real-time persistent key-value store with the same redis protocol. BBVA - Raft backend implementation using BadgerDB for Hashicorp raft. Fantom - aBFT Consensus platform for distributed applications. decred - An open, progressive, and self-funding cryptocurrency with a system of community-based governance integrated into its blockchain. OpenNetSys - Create useful dApps in any software language. HoneyTrap - An extensible and opensource system for running, monitoring and managing honeypots. Insolar - Enterprise-ready blockchain platform. IoTeX - The next generation of the decentralized network for IoT powered by scalability- and privacy-centric blockchains. go-sessions - The sessions manager for Go net/http and fasthttp. Babble - BFT Consensus platform for distributed applications. Tormenta - Embedded object-persistence layer / simple JSON database for Go projects. BadgerHold - An embeddable N
Read the full README on GitHub

What Hacker News says

4 sources

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.