HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
tonsky
datascript
Clojure2014–2026
tonsky / datascript

datascript

Immutable database and Datalog query engine for Clojure, ClojureScript and JS

55Distinct people
74Mentions
0Explicit recommenders
5.8KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

Immutable database and Datalog query engine for Clojure, ClojureScript and JS

GitHub

Where it is used

No documented product use was verified in the last source check.

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

Mentioned in the same Hacker News threads. That is not proof they are substitutes.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 11:56:56 AM 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 year74 dated mentions

Observed mentions: 2014-04-24 14:32:47 UTC to 2026-09-03 15:53:42 UTC.

0369122014-01-01 00:00:00 UTC to 2015-01-01 00:00:00 UTC (exclusive): 4 mentions; 1 submissions, 3 comments20142015-01-01 00:00:00 UTC to 2016-01-01 00:00:00 UTC (exclusive): 10 mentions; 5 submissions, 5 comments2016-01-01 00:00:00 UTC to 2017-01-01 00:00:00 UTC (exclusive): 3 mentions; 0 submissions, 3 comments2017-01-01 00:00:00 UTC to 2018-01-01 00:00:00 UTC (exclusive): 7 mentions; 1 submissions, 6 comments2018-01-01 00:00:00 UTC to 2019-01-01 00:00:00 UTC (exclusive): 6 mentions; 1 submissions, 5 comments2019-01-01 00:00:00 UTC to 2020-01-01 00:00:00 UTC (exclusive): 11 mentions; 3 submissions, 8 comments2020-01-01 00:00:00 UTC to 2021-01-01 00:00:00 UTC (exclusive): 9 mentions; 2 submissions, 7 comments20202021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 4 mentions; 1 submissions, 3 comments2022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 6 mentions; 0 submissions, 6 comments2023-01-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 4 mentions; 0 submissions, 4 comments2024-01-01 00:00:00 UTC to 2025-01-01 00:00:00 UTC (exclusive): 8 mentions; 1 submissions, 7 comments2025-01-01 00:00:00 UTC to 2026-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2026-01-01 00:00:00 UTC to 2027-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments. Incomplete calendar period.2026*

* An incomplete calendar period is marked with an outlined bar. Its count is not directly comparable with a full period.

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
20142014-01-01 00:00:00 UTC2015-01-01 00:00:00 UTC413
20152015-01-01 00:00:00 UTC2016-01-01 00:00:00 UTC1055
20162016-01-01 00:00:00 UTC2017-01-01 00:00:00 UTC303
20172017-01-01 00:00:00 UTC2018-01-01 00:00:00 UTC716
20182018-01-01 00:00:00 UTC2019-01-01 00:00:00 UTC615
20192019-01-01 00:00:00 UTC2020-01-01 00:00:00 UTC1138
20202020-01-01 00:00:00 UTC2021-01-01 00:00:00 UTC927
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC413
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC606
20232023-01-01 00:00:00 UTC2024-01-01 00:00:00 UTC404
20242024-01-01 00:00:00 UTC2025-01-01 00:00:00 UTC817
20252025-01-01 00:00:00 UTC2026-01-01 00:00:00 UTC000
2026 (partial)2026-01-01 00:00:00 UTC2027-01-01 00:00:00 UTC202

What Hacker News says

74 sources
Thanks. Yes happy to hear about other full solutions. By Datomic in the browser you likely mean https://github.com/tonsky/datascript. Full solutions like InstantDB or ConvexDB offer the syncing part, but they don't seem to be doing full incremental queries in the backend, but rather some combination of smart invalidation and then full recalculation of the subscriptions which then get pushed to the clients.
In Show HN: Triplox, a distributed Datalog engine with incremental queries
I'm not terribly familiar with graph databases, but perhaps someone who is can explain the advantage of this awfully complicated seeming design. There's gremlin, cypher, yjs, and zod, all of which I understand are different languages for different problems. What's the advantage of using all these different things in one system? You can do all of this in datalog. You get strong eventual consistency naturally. LLMs know how to write it. It's type safe. JS implementations exist [0]. [0] https://github.com/tonsky/datascript
In A type-safe, realtime collaborative Graph Database in a CRDT
Is the datalog engine exposed? Is there any way to cache parsed queries? Other datalog engines support recursive queries, which makes my life so much easier. Can I do that now with this? Or is it on the roadmap? I have fairly large and overlapping rules/queries. Is there any way to store parsed queries and combine them? Also, why the same name as the (Lutris) Enhydra java database? Your domain is currently listed as a "failed company" from 1997-2000 (actual usage of the Java InstantDB was much longer) https://dbdb.io/db/instantdb Given that it's implemented clojure and some other datalog engines are in clojure, can you say anything about antecedents? Some other Clojure datalog implementations, most in open source - Datomic is the long-standing market leader - XTDB (MPL): https://github.com/xtdb/xtdb - Datascript (EPL): https://gi
Read the rest
thub.com/tonsky/datascript - Datalevin ((forking datascript, EPL): https://github.com/juji-io/datalevin - datahike (forking datascript, EPL): https://github.com/replikativ/datahike - Naga (EPL): https://github.com/quoll/naga
In Show HN: InstantDB – A Modern Firebase
Hi pests, I don't think the criticism in the comments gives a full picture. I wrote about a particular flavor of datalog, in common use today. [1] [2]. The earliest representation I know which matches the syntax of my essay, was in SICP [3] There's another, more academic form of datalog which looks a lot like prolog. There's lots of similarities and [2] mentions them. [1] https://github.com/tonsky/datascript [2] https://docs.datomic.com/pro/query/query.html [3] https://sarabander.github.io/sicp/html/4_002e4.xhtml
In Datalog in 100 lines of JavaScript (2022)
I've been tooling around with "Tuple Database", which claims to be FoundationDB for the frontend (by the original dev of Notion). https://github.com/ccorcos/tuple-database/ I have found it conceptually similar to Relic or Datascript, but with strong preformance guarantees - something Relic considers a potential issue. It also solves the problem of using reactive queries to trigger things like popups and fullscreen requests, which must be run in the same event loop as user input. https://github.com/wotbrew/relic https://github.com/tonsky/datascript Having a full (fast!) database as my React state manager gives me LAMP nostalgia :)
In FoundationDB: A Distributed Key-Value Store
ICYMI, there's an excellent interactive introduction to `datalog` that's referenced in the article's references.[0] Last time I used `datalog` was years ago, I was developing an internal interactive tool that was used to compare different approaches to solving a certain problem at my employer. I used `datascript`[1] by way of clojurescript to store all experiment data and then interrogated the `datascript` DB via `datalog`. This is something I always remember fondly. [0] https://www.learndatalogtoday.org/ [1] https://github.com/tonsky/datascript
In Introduction to Datalog

Showing the 15 most recent of 74 sources. Enable JavaScript to search and browse every indexed mention.

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.