{"slug": "z3", "name": "Z3", "category": "other", "category_name": "Other software", "description": "", "recommenders": 6, "commenters": 21, "warners": 0, "score": 9.059, "rising": 2.02, "first": "2025-11-12", "latest": "2026-10-04", "why": "I'm a fan. I've been building a proof assistant directly on the z3py api.", "why_is_quote": true, "has_verdict": false, "sentiment": {"recommend": 6, "neutral": 12, "compare": 4, "warn": 0}, "spark": [2, 0, 0, 0, 0, 0, 0, 0, 1, 0, 3, 0], "listed": true, "loved": [], "caveat": "", "short_quote": "I'm a fan. I've been building a proof assistant directly on the z3py api.", "kind": "", "icon": true, "domain": null, "github_repo": "github.com/z3prover/z3", "official_url": "https://github.com/Z3Prover/z3", "pricing": "", "aliases": ["Z3"], "verdict": null, "praise": [{"label": "", "summary": "", "quotes": [{"id": 795851136, "item_id": 49740696, "url": "https://news.ycombinator.com/item?id=49740696", "by": "olooney", "date": "2026-09-17", "version": null, "stance": "recommend", "quote": "I like Z3 a lot.", "excerpt": "I like Z3 a lot. I think it's criminally underappreciated and underused. Here is a fairly interesting use I put it to a few years ago: https://www.oranlooney.com/post/playfair/#known-plaintext-attack Slightly more complicated than the toy examples shown in the documentation above, and hints at one of the real world use cases for Z3 - red teaming cryptography. That said, I'm not sure the documentation linked above is ", "context": "", "use_case": "Red teaming cryptography", "switched_from": "", "story": "Online Z3 Guide"}, {"id": 793209296, "item_id": 49575581, "url": "https://news.ycombinator.com/item?id=49575581", "by": "vismit2000", "date": "2026-09-05", "version": null, "stance": "recommend", "quote": "z3 or constraint programming comes in very handy", "excerpt": "z3 or constraint programming comes in very handy in at least one challenge every year in Advent of Code! https://adventofcode.com", "context": "", "use_case": "constraint solving puzzles", "switched_from": "", "story": "Solving the Jane Street reverse engineering challenge"}, {"id": 793056160, "item_id": 49566010, "url": "https://news.ycombinator.com/item?id=49566010", "by": "mdritch", "date": "2026-09-04", "version": null, "stance": "recommend", "quote": "I love z3.", "excerpt": "I love z3. I used it for the first time for Jane Street's puzzle last year involving a hashing alg disguised as a neural network. I use a lot of MCMC at work and I have made a few small investigations into MCMC model formal verification via z3, but nothing real yet. This has inspired me to pick that back up.", "context": "uses MCMC at work", "use_case": "solving puzzles, formal verification", "switched_from": "", "story": "Solving the Jane Street reverse engineering challenge"}, {"id": 782310835, "item_id": 48894427, "url": "https://news.ycombinator.com/item?id=48894427", "by": "mayank", "date": "2026-07-13", "version": null, "stance": "recommend", "quote": "Z3 checks at build time", "excerpt": "TL;DR: Overplane is an AI build system that pairs popular AI coding agents with containers, spec driven development, and automatic lightweight formal verification for a safer, replayable AI codegen workflow. Like many others, I\u2019ve watched AI code pile up at work, and get increasingly lighter reviews due to its size and maddening uniformity. On my side projects at night, I see the full speed and fragility of vibe codi", "context": "", "use_case": "", "switched_from": "", "story": "Show HN: Overplane: Containers and formal verification for AI code"}, {"id": 735286016, "item_id": 45955376, "url": "https://news.ycombinator.com/item?id=45955376", "by": "gbacon", "date": "2025-11-17", "version": null, "stance": "recommend", "quote": "We care about Z3 because it is a Satisfiability Modulo Theories (SMT) solver", "excerpt": "We care about Z3 because it is a Satisfiability Modulo Theories (SMT) solver. Satisfiability: In 1971, Stephen A. Cook established that Boolean satisfiability, given an arbitrary Boolean formula whether an assignment to its variables exists that evaluates true, is NP-complete. https://dl.acm.org/doi/10.1145/800157.805047 Translating between NP-complete problems is at most a polynomial (\u201cfast\u201d) amount of work, so ever", "context": "", "use_case": "SMT solving", "switched_from": "", "story": "Z3 API in Python: From Sudoku to N-Queens in Under 20 Lines (2015)"}]}], "caveats": [], "who": [{"by": "rumblefrog", "context": "senior software engineer at Disney", "url": "https://news.ycombinator.com/item?id=49929695", "date": "2026-10-02"}, {"by": "mdritch", "context": "uses MCMC at work", "url": "https://news.ycombinator.com/item?id=49566010", "date": "2026-09-04"}], "tags": [], "use_cases": ["smt solving", "formal verification of cdn policy", "red teaming cryptography", "constraint solving puzzles", "solving puzzles, formal verification", "constraint solving"], "compared": [{"slug": "lean", "name": "Lean", "co": 2, "switched_from": 0, "switched_to": 0}, {"slug": "dafny", "name": "Dafny", "co": 2, "switched_from": 0, "switched_to": 0}, {"slug": "claude", "name": "Claude", "co": 2, "switched_from": 0, "switched_to": 0}], "makers": [], "threads": [{"url": "https://news.ycombinator.com/item?id=45947301", "title": "Z3 API in Python: From Sudoku to N-Queens in Under 20 Lines (2015)", "mentions": 5}, {"url": "https://news.ycombinator.com/item?id=49562657", "title": "Solving the Jane Street reverse engineering challenge", "mentions": 4}, {"url": "https://news.ycombinator.com/item?id=48750008", "title": "Salt v1.0.0 \u2013 a systems language with Z3 theorem proving in the compiler", "mentions": 2}, {"url": "https://news.ycombinator.com/item?id=49934078", "title": "Results from the ASIC puzzle", "mentions": 1}, {"url": "https://news.ycombinator.com/item?id=49922568", "title": "Ask HN: Who wants to be hired? (October 2026)", "mentions": 1}, {"url": "https://news.ycombinator.com/item?id=49713347", "title": "Online Z3 Guide", "mentions": 1}], "sentiment_by_month": {"2025-11": {"neutral": 3, "compare": 1, "recommend": 2}, "2025-12": {}, "2026-01": {"neutral": 1}, "2026-02": {"neutral": 1}, "2026-03": {"neutral": 2}, "2026-04": {}, "2026-05": {"compare": 1}, "2026-06": {}, "2026-07": {"compare": 2, "neutral": 1, "recommend": 1}, "2026-08": {}, "2026-09": {"neutral": 2, "recommend": 3}, "2026-10": {"neutral": 2}}, "versions": [], "version_unnamed": 0, "family_ref": null, "runs_on": null, "lines": [], "quotes": [{"id": 799333281, "item_id": 49958330, "url": "https://news.ycombinator.com/item?id=49958330", "by": "babush", "date": "2026-10-04", "version": null, "stance": "neutral", "quote": "it basically ended up going the Z3/SMT route", "excerpt": "I asked Claude to \"fuzz the circuit\" and, while it didn't work, it basically ended up going the Z3/SMT route and solving it in ~3 hours. This is after the writeups were already out, but still, as a software reverser, pretty wild. Writeup: https://www.babush.me/how-not-to-solve-jane-streets-asic-puzzle.html", "context": "", "use_case": "", "switched_from": "", "story": "Results from the ASIC puzzle"}, {"id": 798875120, "item_id": 49929695, "url": "https://news.ycombinator.com/item?id=49929695", "by": "rumblefrog", "date": "2026-10-02", "version": null, "stance": "neutral", "quote": "designed intent-based CDN policy controls with Z3 formal verification", "excerpt": "Location: New York, USA Remote: Yes, or Hybrid Willing to relocate: No Technologies: Go, Rust, TypeScript, gRPC/Protobuf, Kubernetes, Nomad, Docker, Terraform, Consul, AWS, Akamai, Fastly, Cloudflare, MySQL, Redis, MongoDB, InfluxDB, Grafana, Datadog, Linux R\u00e9sum\u00e9/CV: https://zhenyangli.me/cv.pdf Email: contact [at] zhenyangli [dot] me --- Primarily looking for mid-size+ companies at the moment. Senior software engin", "context": "senior software engineer at Disney", "use_case": "formal verification of CDN policy", "switched_from": "", "story": "Ask HN: Who wants to be hired? (October 2026)"}, {"id": 795851136, "item_id": 49740696, "url": "https://news.ycombinator.com/item?id=49740696", "by": "olooney", "date": "2026-09-17", "version": null, "stance": "recommend", "quote": "I like Z3 a lot.", "excerpt": "I like Z3 a lot. I think it's criminally underappreciated and underused. Here is a fairly interesting use I put it to a few years ago: https://www.oranlooney.com/post/playfair/#known-plaintext-attack Slightly more complicated than the toy examples shown in the documentation above, and hints at one of the real world use cases for Z3 - red teaming cryptography. That said, I'm not sure the documentation linked above is ", "context": "", "use_case": "Red teaming cryptography", "switched_from": "", "story": "Online Z3 Guide"}, {"id": 795777505, "item_id": 49736094, "url": "https://news.ycombinator.com/item?id=49736094", "by": "Jtsummers", "date": "2026-09-17", "version": null, "stance": "neutral", "quote": "run it through Z3 if I read correctly", "excerpt": "https://verus-lang.github.io/verus/publications-and-projects/ - The papers here go into their implementation. They take the proof statements and information about the program and turn it into an SMT problem (and run it through Z3 if I read correctly) and then they use that to prove the properties of the program. SPARK/Ada and Dafny work similarly, and have good documentation if you want to try your hand at something ", "context": "", "use_case": "", "switched_from": "", "story": "Developing provably correct Rust code with Verus"}, {"id": 793209296, "item_id": 49575581, "url": "https://news.ycombinator.com/item?id=49575581", "by": "vismit2000", "date": "2026-09-05", "version": null, "stance": "recommend", "quote": "z3 or constraint programming comes in very handy", "excerpt": "z3 or constraint programming comes in very handy in at least one challenge every year in Advent of Code! https://adventofcode.com", "context": "", "use_case": "constraint solving puzzles", "switched_from": "", "story": "Solving the Jane Street reverse engineering challenge"}, {"id": 793056160, "item_id": 49566010, "url": "https://news.ycombinator.com/item?id=49566010", "by": "mdritch", "date": "2026-09-04", "version": null, "stance": "recommend", "quote": "I love z3.", "excerpt": "I love z3. I used it for the first time for Jane Street's puzzle last year involving a hashing alg disguised as a neural network. I use a lot of MCMC at work and I have made a few small investigations into MCMC model formal verification via z3, but nothing real yet. This has inspired me to pick that back up.", "context": "uses MCMC at work", "use_case": "solving puzzles, formal verification", "switched_from": "", "story": "Solving the Jane Street reverse engineering challenge"}, {"id": 793011360, "item_id": 49563210, "url": "https://news.ycombinator.com/item?id=49563210", "by": "karelpeeters", "date": "2026-09-04", "version": null, "stance": "compare", "quote": "I hindsight I could probably have used SymbiYosys instead of Z3", "excerpt": "Yeah I briefly considered switching to a simulator to get the final output, but then luckily realized the Z3 setup I had was already acting as a super-powered simulator anyway! I'm not actually using formal verification at $DAYJOB, there we're using MILP solvers (which are closely related to SAT solvers) as part of the compilation flow when scheduling operations onto hardware accelerators. I have been interested in f", "context": "", "use_case": "", "switched_from": "", "story": "Solving the Jane Street reverse engineering challenge"}, {"id": 793008080, "item_id": 49563005, "url": "https://news.ycombinator.com/item?id=49563005", "by": "karelpeeters", "date": "2026-09-04", "version": null, "stance": "neutral", "quote": "how to convert circuits to z3 equations", "excerpt": "Congrats on solving the challenge! I also briefly wrote about my approach here, with less pictures but going into slightly more detail about how to convert circuits to z3 equations: https://gist.github.com/KarelPeeters/dba417c2690cf0505ac9079ca1c609ab", "context": "", "use_case": "SMT solving", "switched_from": "", "story": "Solving the Jane Street reverse engineering challenge"}, {"id": 783788432, "item_id": 48986777, "url": "https://news.ycombinator.com/item?id=48986777", "by": "olooney", "date": "2026-07-20", "version": null, "stance": "compare", "quote": "constraint solving with Z3, which was indeed reasonably fast", "excerpt": "I wrote several polyomino solvers for this project: https://www.oranlooney.com/demos/soma-forest/ One of them used constraint solving with Z3, which was indeed reasonably fast. However, by far the fastest was a simple backtracking solver written in Rust which used bit twiddling to quickly test for intersections. For polyomino's in particular, this represents between 10x and 100x constant speed boost, depending on the", "context": "", "use_case": "Constraint solving", "switched_from": "", "story": "My two year old taught me constraint solving"}, {"id": 782310835, "item_id": 48894427, "url": "https://news.ycombinator.com/item?id=48894427", "by": "mayank", "date": "2026-07-13", "version": null, "stance": "recommend", "quote": "Z3 checks at build time", "excerpt": "TL;DR: Overplane is an AI build system that pairs popular AI coding agents with containers, spec driven development, and automatic lightweight formal verification for a safer, replayable AI codegen workflow. Like many others, I\u2019ve watched AI code pile up at work, and get increasingly lighter reviews due to its size and maddening uniformity. On my side projects at night, I see the full speed and fragility of vibe codi", "context": "", "use_case": "", "switched_from": "", "story": "Show HN: Overplane: Containers and formal verification for AI code"}, {"id": 780446720, "item_id": 48777920, "url": "https://news.ycombinator.com/item?id=48777920", "by": "bneb-dev", "date": "2026-07-03", "version": null, "stance": "neutral", "quote": "Z3 proves the base case (vacuously true at i=0)", "excerpt": "Agree with your overall point. I made some changes to extend the current paradigm a bit: https://github.com/bneb/lattice/blob/main/docs/tutorial/09-contracts.md --- Invariants aren't always inferred automatically. When they aren't, they can be made explicit for Z3 to check. At the moment, bubble sort with array-content invariants is fully provable: fn bubble_sort(arr: Ptr<i32>, n: i64) requires n > 0 ensures forall i", "context": "", "use_case": "theorem proving", "switched_from": "", "story": "Salt v1.0.0 \u2013 a systems language with Z3 theorem proving in the compiler"}, {"id": 780095568, "item_id": 48755973, "url": "https://news.ycombinator.com/item?id=48755973", "by": "difc", "date": "2026-07-01", "version": null, "stance": "compare", "quote": "do you see Z3 as a better fit than lean?", "excerpt": "Moving theorem proving upstream into compilers, sandboxes, and the browser seems like the future when we're dealing with increasingly sophisticated AIs. I'm working on similar formal methods but applied to agent sandboxing; do you see Z3 as a better fit than lean? https://github.com/coproduct-opensource/nucleus", "context": "working on formal methods for agent sandboxing", "use_case": "agent sandboxing formal methods", "switched_from": "", "story": "Salt v1.0.0 \u2013 a systems language with Z3 theorem proving in the compiler"}, {"id": 770861696, "item_id": 48178856, "url": "https://news.ycombinator.com/item?id=48178856", "by": "jodrellblank", "date": "2026-05-18", "version": null, "stance": "compare", "quote": "only available as library code (e.g. Z3 constraint solver)", "excerpt": "I relate to \"I wrote it in Prolog, it works on a test example, it doesn't work on the full thing and I don't know if it will ever finish\", and that was why I stopped my last attempt at Advent of Code in Prolog. It took me hours longer to make something which worked, it was more code, and it never finished on the full puzzle, and I was fed up and had no motivation or approach to discovering why. But I think it's diffe", "context": "", "use_case": "", "switched_from": "", "story": "Prolog Basics Explained with Pok\u00e9mon"}, {"id": 758584578, "item_id": 47411536, "url": "https://news.ycombinator.com/item?id=47411536", "by": "hnipps", "date": "2026-03-17", "version": null, "stance": "neutral", "quote": "uses Dafny (backed by Z3)", "excerpt": "Author here. I picked this problem because it was assigned to me in Jira. Energy usage attribution logic for smart EV charging incentives in Python/Django. Pure arithmetic, clear postconditions. Best possible case for formal verification. If it couldn't prove its value here, it couldn't prove it anywhere. So I built a Claude Code plugin called Crosscheck that uses Dafny (backed by Z3). Five proof obligations, all dis", "context": "", "use_case": "", "switched_from": "", "story": "I formally verified AI-generated code. All 4 bugs were in the integration layer"}, {"id": 756879249, "item_id": 47304953, "url": "https://news.ycombinator.com/item?id=47304953", "by": "kameama", "date": "2026-03-08", "version": null, "stance": "neutral", "quote": "Z3 search scripts", "excerpt": "A 16\u00d716 multiplication table that encodes quoting, evaluation, branching, recursion, an 8-state counter, and IO \u2014 all as lookups in the same table. 83 Lean theorems, zero sorry. The project asks: can a finite algebra with a single binary operation be forced by axioms to contain its own representation layer? The answer is yes. Axiom-driven SAT search finds the constraints, Lean verifies the witness. I should be upfron", "context": "", "use_case": "", "switched_from": "", "story": "Ask HN: What Are You Working On? (March 2026)"}, {"id": 751730000, "item_id": 46983125, "url": "https://news.ycombinator.com/item?id=46983125", "by": "VirgilH2Oss", "date": "2026-02-11", "version": null, "stance": "neutral", "quote": "You can get it here with the Z3 theorem audit, a CAS audit", "excerpt": "Just published a Lemma you might find interesting. Would love feedback. You can get it here with the Z3 theorem audit, a CAS audit and an audit for the Heisenberg's derivation. -Abstract Observation is performed using light or its physical equivalent. Light is also what is being observed. Lorentz worked with fields, mathematically inheriting the limitations of field-based assumptions; treating light as a physical obj", "context": "", "use_case": "", "switched_from": "", "story": "The Observer Lemma"}, {"id": 743723456, "item_id": 46482716, "url": "https://news.ycombinator.com/item?id=46482716", "by": "DylanSp", "date": "2026-01-03", "version": null, "stance": "neutral", "quote": "I've been learning the basics of using Z3", "excerpt": "I've been learning the basics of using Z3 by creating a solver for the daily puzzle game Clues By Sam (very fun game; https://cluesbysam.com/). Repo is https://github.com/DylanSp/clues-by-sam-solver. It uses Playwright to read clues and submit guesses; I've got it working for all 50 puzzles in puzzle pack 1.", "context": "", "use_case": "", "switched_from": "", "story": "Ask HN: What are you working on? (Jan 2026)"}, {"id": 735286016, "item_id": 45955376, "url": "https://news.ycombinator.com/item?id=45955376", "by": "gbacon", "date": "2025-11-17", "version": null, "stance": "recommend", "quote": "We care about Z3 because it is a Satisfiability Modulo Theories (SMT) solver", "excerpt": "We care about Z3 because it is a Satisfiability Modulo Theories (SMT) solver. Satisfiability: In 1971, Stephen A. Cook established that Boolean satisfiability, given an arbitrary Boolean formula whether an assignment to its variables exists that evaluates true, is NP-complete. https://dl.acm.org/doi/10.1145/800157.805047 Translating between NP-complete problems is at most a polynomial (\u201cfast\u201d) amount of work, so ever", "context": "", "use_case": "SMT solving", "switched_from": "", "story": "Z3 API in Python: From Sudoku to N-Queens in Under 20 Lines (2015)"}, {"id": 735246912, "item_id": 45952932, "url": "https://news.ycombinator.com/item?id=45952932", "by": "philzook", "date": "2025-11-17", "version": null, "stance": "recommend", "quote": "I'm a fan. I've been building a proof assistant directly on the z3py api.", "excerpt": "I'm a fan. I've been building a proof assistant directly on the z3py api. https://pypi.org/project/knuckledragger/0.1.3/", "context": "", "use_case": "", "switched_from": "", "story": "Z3 API in Python: From Sudoku to N-Queens in Under 20 Lines (2015)"}, {"id": 735231280, "item_id": 45951955, "url": "https://news.ycombinator.com/item?id=45951955", "by": "raphman", "date": "2025-11-17", "version": null, "stance": "neutral", "quote": "contains many Z3 examples", "excerpt": "\"SAT/SMT by Example\" also contains many Z3 examples (and has a new URL): https://smt.st/", "context": "", "use_case": "SMT solving examples", "switched_from": "", "story": "Z3 API in Python: From Sudoku to N-Queens in Under 20 Lines (2015)"}, {"id": 735228848, "item_id": 45951803, "url": "https://news.ycombinator.com/item?id=45951803", "by": "Recursing", "date": "2025-11-17", "version": null, "stance": "compare", "quote": "Have you tried to compare Z3 with cvc5?", "excerpt": "Have you tried to compare Z3 with cvc5? https://cvc5.github.io/docs/cvc5-1.1.2/api/python/pythonic/pythonic.html It offers basically the same API and could be faster in many cases", "context": "", "use_case": "", "switched_from": "", "story": "Z3 API in Python: From Sudoku to N-Queens in Under 20 Lines (2015)"}, {"id": 735228401, "item_id": 45951775, "url": "https://news.ycombinator.com/item?id=45951775", "by": "tyilo", "date": "2025-11-17", "version": null, "stance": "neutral", "quote": "I always use that instead of the z3-solver directly.", "excerpt": "I have created a Python library called \"z4-solver\" that adds some nice utility functions on top of z3: https://github.com/Tyilo/z4 I always use that instead of the z3-solver directly.", "context": "", "use_case": "SMT solver", "switched_from": "", "story": "Z3 API in Python: From Sudoku to N-Queens in Under 20 Lines (2015)"}, {"id": 734413520, "item_id": 45900845, "url": "https://news.ycombinator.com/item?id=45900845", "by": "mpcsb", "date": "2025-11-12", "version": null, "stance": "neutral", "quote": "I used the Z3 SMT solver to test if two models are logically equivalent", "excerpt": "My post: I used the Z3 SMT solver to test if two models are logically equivalent across the entire input space (not just in the sample data). It either finds a counterexample or proves none exists. To be considered when simplifying complex models or when retraining routines in mlops. Post includes code and discussion.", "context": "", "use_case": "proving ML model equivalence", "switched_from": "", "story": "Proving two ML models are equivalent using Z3 (with code)"}]}