Embedded Databases Compared: Engines That Ship Inside

The best embedded database software is SQLite for general-purpose in-process SQL, DuckDB for embedded analytics, ObjectBox for fast object storage on devices, Couchbase Lite for mobile apps that sync, and LiteDB or H2 for dotnet and Java applications respectively, depending on the application you are building

Ranked list

  1. SQLite — General local SQL
  2. DuckDB — Embedded analytics
  3. ObjectBox — Objects on mobile and IoT
  4. Couchbase Lite — Offline mobile with sync
  5. LiteDB — Dotnet document storage
  6. H2 — Java embedded SQL and tests
  7. Actian Zen — Supported ISV embedding
Key takeaways
  • Most leaders are free. SQLite, DuckDB, LiteDB and H2 are open source and cost nothing to embed or ship.
  • Embedded means in-process. The engine links into your application instead of running as a separate server.
  • Sync is the paid frontier. Mobile sync and enterprise support are where commercial licenses appear.
  • Choose by data shape. Relational, analytical, object and document workloads each favor a different engine here.

What makes a database embedded?

An embedded database runs inside your application's process. There is no server to install, no port to secure and no administrator to hire; the library reads and writes data files directly.

That model powers desktop software, mobile apps, edge devices and test suites. It also powers more servers than most teams realize, through tools that embed these engines quietly.

The trade is concurrency and scale. Embedded engines excel at local, single-application data and strain under many simultaneous writers or multi-node designs.

Which embedded databases should you consider?

SQLite

SQLite is the most deployed database in the world, shipping in phones, browsers and operating systems. It stores a whole database in one file and needs zero configuration.

Its SQL coverage is remarkably complete for its size. For local application data, it is the default answer until requirements prove otherwise.

Best for: General-purpose local SQL storage in almost any application.

  • Single-file database format
  • Full SQL with transactions
  • Public domain source code
  • Bindings for nearly every language

Pricing: Free. SQLite is in the public domain, with optional commercial support and extensions sold by Hwaci for organizations that want them.

Limitation: One writer at a time. High-concurrency write workloads and client-server designs belong on a server database instead.

DuckDB

DuckDB is an in-process analytical database, often described as SQLite for analytics. It runs columnar queries over local files and data lakes with strong performance.

It reads Parquet and CSV directly and plugs into Python data workflows. Analysts and data engineers use it to query large datasets without standing up infrastructure.

Best for: Embedded analytics and local querying of file-based data.

  • Columnar vectorized query engine
  • Direct Parquet, CSV and JSON queries
  • Strong Python and R integration
  • Extensions for formats and sources

Pricing: Free and open source under the MIT license. DuckDB Labs sells support and consulting, and MotherDuck sells a separate cloud service.

Limitation: Analytics-first design. Transactional workloads with many small writes fit SQLite or a server database better.

ObjectBox

ObjectBox is an object database built for mobile and IoT devices. Developers store objects directly without mapping to tables, and queries run with native speed.

Its sync product moves data between devices and servers, which is where commercial licensing begins. The core database targets Android, iOS and embedded Linux.

Best for: Mobile and edge apps storing objects with offline-first behavior.

  • Native object storage, no ORM layer
  • Fast on-device performance
  • Data sync add-on for multi-device apps
  • Small footprint for IoT

Pricing: The core database is free to use. Sync and commercial terms are priced by the vendor, so treat those as quote-based.

Limitation: Smaller ecosystem than SQLite. Hiring, examples and third-party tooling are thinner when you hit unusual problems.

Couchbase Lite

Couchbase Lite is an embedded document database for mobile and edge applications. It stores JSON documents locally and syncs with Couchbase Server through Sync Gateway when connected.

Offline-first apps are its home ground: field service, retail and healthcare apps that must work disconnected, then reconcile. SQL-style querying sits over the document store.

Best for: Mobile apps needing offline storage with managed sync to a server.

  • Embedded JSON document storage
  • Peer and cloud sync options
  • SQL-based query language
  • iOS, Android and desktop support

Pricing: A free community edition exists. Enterprise editions with support and full sync features are licensed commercially through Couchbase, priced by quote.

Limitation: Full value needs the Couchbase server stack. Standalone local use gives up the sync story that justifies the platform.

LiteDB

LiteDB is a serverless document database written for dotnet. It ships as a single managed assembly and stores data in one file, with an API that feels like a tiny MongoDB.

Desktop and utility applications in the Microsoft ecosystem use it to skip SQL mapping. LINQ support makes queries feel native to C sharp developers.

Best for: Dotnet applications needing simple embedded document storage.

  • Single-assembly deployment
  • Document storage with LINQ queries
  • Single-file database format
  • Studio tool for inspection

Pricing: Free and open source under the MIT license. There is no commercial edition; support is community-based.

Limitation: Dotnet only, and project pace is community-driven. Cross-platform language needs point back to SQLite or DuckDB.

H2

H2 is a Java SQL database that runs embedded, in-memory or as a small server. It is famous as the test and development database behind countless Java applications.

Its compatibility modes emulate other databases, which helps migrations and testing. Many teams meet H2 in test suites long before considering it for production.

Best for: Java applications, prototypes and test environments needing embedded SQL.

  • Embedded, memory and server modes
  • Compatibility modes for major databases
  • Small single-jar footprint
  • Browser-based console

Pricing: Free and open source under the Mozilla Public License and Eclipse Public License. No commercial license is required.

Limitation: Production ambitions should be modest. For durable, high-write production data, the community generally steers users to server databases.

Actian Zen

Actian Zen, formerly Pervasive PSQL, is a commercial embedded database with decades in packaged software. It offers both transactional and SQL access to the same data.

Independent software vendors embed it when they need a maintained, supported engine with royalty models. Edge and IoT editions target small footprints.

Best for: Software vendors needing a commercially supported embeddable engine.

  • Transactional and relational access
  • Embedded and workgroup editions
  • Long-term vendor support
  • Low administration design

Pricing: Pricing: see vendor site (quote-based). Actian licenses Zen by edition and deployment, with ISV terms set through sales.

Limitation: Mindshare is low among modern developers. Community knowledge and hiring familiarity trail the open source leaders.

How do these embedded databases compare side by side?

ToolBest forStarting priceFree plan/trial
SQLiteGeneral local SQLFreeFree, public domain
DuckDBEmbedded analyticsFreeFree open source
ObjectBoxObjects on mobile and IoTFree coreFree core database
Couchbase LiteOffline mobile with syncFree community editionFree community edition
LiteDBDotnet document storageFreeFree open source
H2Java embedded SQL and testsFreeFree open source
Actian ZenSupported ISV embeddingSee vendor site (quote-based)Evaluation via vendor

Price rarely decides this category, because the leaders are free. The real costs are fit, durability behavior and the engineering time around sync and upgrades.

Commercial engines hide elsewhere in your stack too. An unused license check across your database estate often funds the support contracts that do matter.

How much does embedded database software cost?

Mostly nothing. SQLite, DuckDB, LiteDB and H2 are free to embed and redistribute, and ObjectBox and Couchbase Lite offer free tiers or editions for local use.

Money enters through sync, support and ISV licensing. Example: a vendor shipping a million devices negotiates embedding and support terms that a single internal app never needs.

Tip: Read the license before you fall in love. Public domain and MIT terms ship anywhere, while some free editions restrict commercial sync features.

Support is the other paid layer. Regulated products often buy Hwaci or Couchbase support for accountability, not for features.

How did we choose these embedded databases?

We required engines that genuinely run in-process inside an application. Server databases with small editions and hosted databases were excluded, however good they are.

Scoring weighted data model fit, language reach, durability behavior and licensing clarity. Free and open source status is stated exactly as each project publishes it.

Only Actian Zen hides pricing behind quotes here. The rest publish their free or open terms openly, and entries reflect that.

Which embedded database should you pick?

Start from your data shape and language, not from popularity.

  1. Pick SQLite for default local SQL in any language.
  2. Pick DuckDB when the local work is analytical queries over files.
  3. Pick Couchbase Lite or ObjectBox for offline mobile apps, especially with sync.
  4. Pick LiteDB or H2 inside dotnet and Java applications respectively.

Whichever you choose, test your upgrade path. Our app rationalization guidance shows why engine choices compound across a product portfolio.

Prototype with your real data volume. Embedded engines behave beautifully at a thousand rows and very differently at fifty million, and the gap surprises teams regularly.

Our blog covers data tooling decisions in the same spirit: the boring, proven engine usually beats the fashionable one for local storage.

What should you check before embedding?

Test corruption behavior. Pull power mid-write on real hardware and see what survives; embedded data often lives on devices you do not control.

Check file format stability across versions. Your users will open five-year-old databases with new builds, and migration pain arrives silently if formats drift.

Finally, confirm write concurrency honestly. If two processes or many threads must write at once, you may need a server database wearing an embedded costume.

Sources

  • Project and vendor pages for SQLite, DuckDB, ObjectBox, Couchbase Lite, LiteDB, H2 and Actian Zen, checked November 2026; open source terms are as published by each project.

Frequently asked questions

What is the difference between embedded and server databases?

An embedded database runs as a library inside your application process and stores data in local files. A server database runs as its own process and serves many applications over a network. The format question matters too: single-file databases simplify backup, shipping and support in ways multi-file engines cannot match.

Is SQLite really free for commercial products?

Yes. SQLite is in the public domain, so commercial products embed it without license fees. Optional paid support and specialized extensions exist for organizations that want them.

When should I choose DuckDB over SQLite?

Choose DuckDB for analytical work: aggregations and scans over large local datasets or Parquet files. Choose SQLite for transactional application data with frequent small reads and writes. For most applications the honest answer is SQLite until a specific requirement, such as analytics or sync, clearly points somewhere else.

Can embedded databases sync between devices?

Some can. Couchbase Lite syncs through Sync Gateway, and ObjectBox sells a sync product. SQLite and DuckDB leave sync to you or to third-party extensions.

Are embedded databases safe for production?

Yes, within their design limits. SQLite powers production software at enormous scale. The failures come from ignoring its single-writer model or from skipping backup and corruption testing. Whichever engine you choose, document the decision and its limits. Future maintainers inherit the database long after the original reasons are forgotten.