DEV.co
Open-Source Databases · Softmotions

ejdb

EJDB2 is a lightweight, embeddable JSON database engine written in C that stores documents in a single file. It supports a query language (JQL) inspired by XPath, offers HTTP/WebSocket network endpoints, and provides native bindings for multiple languages including Swift, Java, Dart, and Node.js.

Source: GitHub — github.com/Softmotions/ejdb
1.5k
GitHub stars
134
Forks
C
Primary language
MIT
License (OSI-approved)

Key facts

Objective fields from the source. Values we can't verify are shown as “Unknown” rather than guessed.

FieldValue
RepositorySoftmotions/ejdb
OwnerSoftmotions
Primary languageC
LicenseMIT — OSI-approved
Stars1.5k
Forks134
Open issues35
Latest releasev2.73 (2022-11-14)
Last updated2026-07-07
Sourcehttps://github.com/Softmotions/ejdb

What ejdb is

EJDB2 is a C11-based embedded JSON database with a custom query language (JQL) for filtering, projecting, and modifying documents. It uses IOWOW as its persistent key-value storage backend and IWNET for HTTP/WebSocket APIs, supporting collection joins, indexes, and online backups.

Quickstart

Get the ejdb source

Clone the repository and explore it locally.

terminalbash
git clone https://github.com/Softmotions/ejdb.gitcd ejdb# follow the project's README for install & configuration

Need it deployed, integrated, or customized instead? DEV.co ships production installs.

Best use cases

Mobile and embedded applications

Native bindings for iOS (Swift), Android (Java/Kotlin via JNI), Flutter (Dart), and React Native make EJDB2 suitable for offline-first mobile apps requiring embedded JSON document storage without external database dependencies.

Single-file document storage in C/C++ applications

Ideal for desktop, IoT, and systems software where embedding a JSON database directly in the application binary eliminates external service management and simplifies distribution.

Edge computing and local-first deployments

The embeddable, single-file nature and optional HTTP/WebSocket API enable edge nodes and distributed systems to maintain local JSON data stores with optional network synchronization.

Implementation considerations

  • C library requires careful memory management in host code; consider language bindings (Swift, Java, Dart, Node.js) to reduce complexity.
  • Single-file database means no built-in replication; implement custom synchronization logic if multi-device sync is required.
  • JQL has no SQL-like joins for multiple collections; collection joins exist but have different semantics than relational outer joins.
  • HTTP/WebSocket API (jbs) must be deployed separately if network access is needed; consider authentication (X-Access-Token) and network isolation.
  • Index creation and performance tuning require understanding of JQL query patterns; lack of query planner visibility may complicate optimization.

When to avoid it — and what to weigh

  • High-performance distributed systems — EJDB2 is optimized for embedded and mobile use cases, not horizontal scaling. If you need multi-node replication, sharding, or distributed consensus, use PostgreSQL, MongoDB, or CockroachDB instead.
  • Complex relational queries — JQL is simpler than SQL and lacks features like window functions, recursive CTEs, and complex aggregations. Relational workloads are better served by PostgreSQL or similar.
  • Real-time analytics and OLAP — EJDB2 is transactional (OLTP-oriented). Time-series, analytical, and columnar workloads should use ClickHouse, TimescaleDB, or similar specialized systems.
  • Requires commercial support or SLA guarantees — Issues tracker is disabled and the project is maintained but not by a company offering commercial support contracts. Community-driven maintenance may not meet enterprise SLA requirements.

License & commercial use

MIT License: permissive, allows commercial use, modification, distribution, and proprietary derivatives with minimal restrictions. Requires only license and copyright notice retention.

MIT license explicitly permits commercial use without royalties or vendor approval. However, no vendor provides commercial support, SLAs, or indemnification. Organizations requiring enterprise support, maintenance guarantees, or liability coverage should conduct independent legal review and consider establishing internal support arrangements or alternative databases with commercial backing.

DEV.co evaluation signals

Editorial assessment — not user reviews. Directional, with an explicit confidence level.

SignalAssessment
MaintenanceActive
DocumentationAdequate
License clarityClear
Deployment complexityLow
DEV.co fitGood
Assessment confidenceHigh
Security considerations

HTTP/WebSocket API uses token-based authentication (X-Access-Token header) with no built-in TLS enforcement visible in documentation; deploy behind reverse proxy with TLS termination. No published security audit, vulnerability disclosure process, or hardening guidance. Single-file database has no encryption-at-rest; filesystem permissions are the only access control. Consider threat modeling for sensitive data storage.

Alternatives to consider

SQLite

Single-file embedded database with mature ecosystem, stronger query language (SQL), wider language support, and formal security audit history. Use if you need relational queries or prefer a more established project.

Firebase Realtime Database / Firestore

Cloud-hosted JSON document store with built-in replication, multi-user sync, and commercial support from Google. Use if you need managed infrastructure and cross-device synchronization without self-hosting.

Realm

Embeddable JSON-like database optimized for mobile (iOS, Android, React Native, Dart) with transparent object mapping and cloud sync options. Use if your primary target is mobile and you want opinionated schema/sync.

Software development agency

Build on ejdb with DEV.co software developers

Our engineers can assess whether EJDB2 fits your architecture, evaluate embedded database alternatives, and guide secure deployment. Contact us for a technical consultation.

Talk to DEV.co

Related open-source tools

Surfaced by semantic similarity across the DEV.co open-source index.

Related on DEV.co

Explore the category and the services that help you build with it.

ejdb FAQ

Can EJDB2 be used in a commercial product?
Yes, MIT license permits commercial use. However, there is no commercial vendor support; you are responsible for security, bug fixes, and maintenance. Verify internal legal compliance for your use case.
Does EJDB2 support multi-process or multi-user access?
Unknown from documentation. Single-file storage suggests limitations, but no explicit concurrency documentation is provided. Test or review source code before relying on concurrent access patterns.
How do I synchronize EJDB2 data across devices?
EJDB2 has no built-in replication. You must implement custom sync logic (e.g., export JSON, transmit over HTTP, re-import). Consider Realm or Firebase if cross-device sync is a primary requirement.
What platforms does EJDB2 support?
Core C library: Linux, macOS, FreeBSD, Windows. Language bindings: iOS (Swift), Android (Java/JNI), Flutter (Dart), Node.js, and React Native. Verify platform-specific binding maturity before adopting.

Custom software development services

DEV.co is a software development agency delivering custom software development services to companies building on open source. Our software developers and web developers design, integrate, and ship production systems — spanning web development, APIs, AI, data, and cloud. If ejdb is part of your open-source databases roadmap, our team can implement, customize, migrate, and maintain it.

Need Help Evaluating EJDB2 for Your Project?

Our engineers can assess whether EJDB2 fits your architecture, evaluate embedded database alternatives, and guide secure deployment. Contact us for a technical consultation.