pouchdb is a free, open source databases project written in JavaScript and released under Apache-2.0. It has 17,609 GitHub stars, 1,505 forks and 189 open issues, and was last pushed 5 days ago. On this registry it ranks #36 of 143 tracked projects in Databases, with 5 head-to-head comparisons available.

What is pouchdb?

PouchDB is an open-source JavaScript database, inspired by Apache CouchDB, that is designed to run well within the browser so web developers can build applications that work as well offline as they do online.

What it is

Apache PouchDB is an open-source JavaScript database inspired by Apache CouchDB, built to run well inside the browser. It lives under the Apache Software Foundation and is currently undergoing incubation there, which is why the repository ships a disclaimer for incubator projects. The project is licensed under Apache-2.0, is written in JavaScript, and is distributed primarily through npm as the package pouchdb, with a parallel jsDelivr distribution for direct web use. The repository is not a single script: it holds multiple packages plus the documentation website in the /docs folder, and the website deploys automatically once changes land on master.

The concrete problem it addresses is the gap between a database that only exists on a server and an application that has to keep working when the network does not. PouchDB puts the datastore in the client runtime itself, in the JavaScript and browser ecosystem the project's topics describe, so reads and writes do not depend on a round trip to a backend before the application can respond. Sync is not an add-on feature of the design; it is the stated purpose, captured in the project's own tagline, "The Database that Syncs!" For a web application that would otherwise stall or break the moment connectivity drops, this replaces the pattern of a datastore that exists only on the server and leaves the client with no local copy of its own data.

Key capabilities

  • Runs as a JavaScript database inside the browser, and installs from npm under the package name pouchdb.
  • Places synchronization at the centre of its design, as stated in the project tagline "The Database that Syncs!" and reinforced by couchdb in its topic list.
  • Traces its data model and API inspiration to Apache CouchDB, and is documented through the site at pouchdb.com and the API reference at pouchdb.com/api.html.
  • Auto-migrates stored data: a database created in 1.0.0 still works when opened in 4.0.0 or later, and any release containing a migration is marked in the release notes.
  • Follows semantic versioning, with a concise wiki list of breaking changes maintained alongside the GitHub releases page.
  • Builds from source for bleeding-edge use: git clone, then npm install, producing the browser build at packages/node_modules/pouchdb/dist/pouchdb.js.
  • Keeps its documentation website in the same repository, under /docs, so documentation changes ship through the normal pull request path.

Who uses it and how

  • Web developers building applications that must behave as well offline as they do online, which the README names as the reason the project was created.
  • Teams working in the JavaScript and browser stack that want a datastore living in the client rather than behind every request.
  • Projects already invested in the CouchDB ecosystem, for which PouchDB appears in the same topic grouping.
  • Contributors of all kinds, since the repository invites code, documentation, website design, blog posts and support answers, and carries the hacktoberfest topic.
  • Users who need help through the established channels: #pouchdb on the CouchDB Slack, the Google Groups mailing list, StackOverflow under the pouchdb tag, or Mastodon at @pouchdb.

Getting started

Install the npm package pouchdb and follow the API documentation at pouchdb.com/api.html. For prerelease builds, clone the repository, run npm install, and take the browser build from packages/node_modules/pouchdb/dist/pouchdb.js.

How it compares

No list of paid products is provided in the available facts, so the comparison rests on the one related tool the facts do name: Apache CouchDB, the project PouchDB takes its inspiration from and shares a topic grouping with. The distinction the facts support is placement rather than purpose, with CouchDB as the server-side system that inspired the design and PouchDB as the pocket-sized JavaScript implementation intended to run in the browser.

When to use it — and when not to

Choose PouchDB when the application genuinely needs a JavaScript datastore in the client and synchronization between that client copy and the rest of the system. Be aware that the README is deliberately thin and defers to the website for almost everything beyond a source build, that the only build instructions documented are the prerelease steps, and that the project is still in Apache incubation with 189 open issues, so governance and interfaces are not fully settled. Anyone wanting a server-only database, or a project that must avoid the churn of an incubating dependency, should look elsewhere for now.

project readme (upstream, from github) — read inline

Apache PouchDB – The Database that Syncs!

Build Status npm version jsDelivr Hits

Apache PouchDB is an open-source JavaScript database inspired by Apache CouchDB that is designed to run well within the browser.

PouchDB was created to help web developers build applications that work as well offline as they do online.

Apache PouchDB is currently undergoing Incubation at the Apache Software Foundation. Read the ASF Disclaimer for incubator projects.

Using PouchDB

To get started using PouchDB, check out the web site and API documentation.

Getting Help

The PouchDB community is active in #pouchdb on the CouchDB Slack, in the Google Groups mailing list, and on StackOverflow. Or you can mastodon @pouchdb!

If you think you've found a bug in PouchDB, please write a reproducible test case and file a Github issue.

Prerelease builds

If you like to live on the bleeding edge, you can build PouchDB from source using these steps:

git clone https://github.com/pouchdb/pouchdb.git
cd pouchdb
npm install

After running these steps, the browser build can be found in packages/node_modules/pouchdb/dist/pouchdb.js.

Changelog

PouchDB follows semantic versioning. To see a changelog with all PouchDB releases, check out the Github releases page.

For a concise list of breaking changes, there's the wiki list of breaking changes.

Keep in mind that PouchDB is auto-migrating, so a database created in 1.0.0 will still work if you open it in 4.0.0+. Any release containing a migration is clearly marked in the release notes.

Contributing

We're always looking for new contributors! If you'd like to try your hand at writing code, writing documentation, designing the website, writing a blog post, or answering questions on StackOverflow, then we'd love to have your input.

If you have a pull request that you'd like to submit, please read the contributing guide for info on style, commit message format, and other (slightly!) nitpicky things like that. PouchDB is heavily tested, so you'll also want to check out the testing guide.

The pouchdb.com Website

The documentation website at pouchdb.com is also part of this repo, in the /docs folder. It has its own /docs/WEBSITE_README.md

Website deployment happens automatically once the changes land in master.

Frequently asked questions

Is pouchdb free to use?

pouchdb is open source under the Apache-2.0 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 pouchdb do?

:kangaroo: - PouchDB is a pocket-sized database.

What is pouchdb written in?

pouchdb is primarily written in JavaScript. Its source is publicly available at https://github.com/apache/pouchdb, and it has 17,609 GitHub stars.