You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
craig[bot] 85e146e1d7 Merge #95190 6 hours ago
.github kvflowcontrol,raftlog: interfaces for replication control 1 day ago
build Merge #96040 21 hours ago
c-deps c-deps: update jemalloc to 5.3.0 3 weeks ago
cloud cloud/kubernetes: update to v22.2.3 3 days ago
docs Merge #95190 6 hours ago
githooks githooks: delete vendor and pkg/ui/yarn-vendor dirs if unneeded 2 weeks ago
licenses sql: Fork a pkg/json package 3 months ago
monitoring monitoring: Added Splunk Dashboard xml files 2 months ago
pkg Merge #95190 6 hours ago
scripts scripts: add one more example to pprof-loop 3 days ago
tools bazel: revert change to enable parallel output bases by default 6 months ago
.bazelignore bazel: add unused lint 7 months ago
.bazelrc .bazelrc: use explicit PATH on macOS 2 months ago
.bazelversion bazel: upgrade to bazel 5.1.0 10 months ago
.editorconfig opt: use 4 space indentation for .opt files 3 years ago
.gitattributes git: remove `distdir_files.bzl` from `git` text diffs 9 months ago
.gitignore build: delete `vendor` submodule 2 months ago
.gitmodules ui: use NPM dependencies mirrored to GCS bucket instead of yarn-vendored 3 weeks ago
.node-version build: match .node-version to Bazel-installed Node version 10 months ago
AUTHORS Merge pull request #95074 from MiladGHeydari/mheydari_authors 2 weeks ago
BUILD.bazel go.mod: import etcd/raft at the new path 1 month ago toplevel: add reference to code of conduct 9 months ago toplevel: add reference to code of conduct 9 months ago
DEPS.bzl go.mod: bump Pebble to 4199154043c5 2 days ago update external contributor hall of fame 2 years ago
LICENSE licenses: Add BSL.txt 4 years ago
Makefile ui: use NPM dependencies mirrored to GCS bucket instead of yarn-vendored 3 weeks ago DOC-4629: Update SQL diagrams surrounding storage parameters 7 months ago
TEAMS.yaml Introduction of the Key Visualizer 3 days ago
WORKSPACE ui: use NPM dependencies mirrored to GCS bucket instead of yarn-vendored 3 weeks ago
dev dev: v69 1 month ago
go.mod go.mod: bump Pebble to 4199154043c5 2 days ago
go.sum go.mod: bump Pebble to 4199154043c5 2 days ago

CockroachDB is a cloud-native distributed SQL database designed to build, scale, and manage modern, data-intensive applications.

What is CockroachDB?

CockroachDB is a distributed SQL database built on a transactional and strongly-consistent key-value store. It scales horizontally; survives disk, machine, rack, and even datacenter failures with minimal latency disruption and no manual intervention; supports strongly-consistent ACID transactions; and provides a familiar SQL API for structuring, manipulating, and querying data.

For more details, see our FAQ or architecture document.


For guidance on installation, development, deployment, and administration, see our User Documentation.

Starting with CockroachCloud

We can run CockroachDB for you, so you don't have to run your own cluster.

See our online documentation: Quickstart with CockroachCloud

Starting with CockroachDB

  1. Install CockroachDB: using a pre-built executable or build it from source.
  2. Start a local cluster and connect to it via the built-in SQL client.
  3. Learn more about CockroachDB SQL.
  4. Use a PostgreSQL-compatible driver or ORM to build an app with CockroachDB.
  5. Explore core features, such as data replication, automatic rebalancing, and fault tolerance and recovery.

Client Drivers

CockroachDB supports the PostgreSQL wire protocol, so you can use any available PostgreSQL client drivers to connect from various languages.


  • CockroachCloud - Steps to create a free CockroachCloud cluster on your preferred Cloud platform.
  • Manual - Steps to deploy a CockroachDB cluster manually on multiple machines.
  • Cloud - Guides for deploying CockroachDB on various cloud platforms.
  • Orchestration - Guides for running CockroachDB with popular open-source orchestration systems.

Need Help?

Building from source

See our wiki for more details.


We welcome your contributions! If you're looking for issues to work on, try looking at the good first issue list. We do our best to tag issues suitable for new external contributors with that label, so it's a great way to find something you can help with!

See our wiki for more details.

Engineering discussions take place on our public mailing list, Also please join our Community Slack (there's a dedicated #contributors channel!) to ask questions, discuss your ideas, and connect with other contributors.


For an in-depth discussion of the CockroachDB architecture, see our Architecture Guide. For the original design motivation, see our design doc.


Current CockroachDB code is released under a combination of two licenses, the Business Source License (BSL) and the Cockroach Community License (CCL).

When contributing to a CockroachDB feature, you can find the relevant license in the comments at the top of each file.

For more information, see the Licensing FAQs.

Comparison with Other Databases

To see how key features of CockroachDB stack up against other databases, check out CockroachDB in Comparison.

See Also