For the complete documentation index, see llms.txt
Concepts
Understand the core ideas behind Midnight, including confidentiality with zero-knowledge proofs, contracts, and verifiable computation.
Core concepts cover these terms
| Concept | Explanation |
|---|---|
| Who interacts | Accounts define who participates on Midnight. They manage keys, addresses, and authorization. This shows who acts in the system. |
| Where data lives | Ledgers store state. Public ledger state is on chain and anyone can read it. Private state stays with you, on your machine. The chain sees proofs and commitments in its place, plus any values you disclose. See On-chain visibility. This shows where state is stored and who can see it. |
| How value moves | The UTXO model defines spendable pieces of value or state. Midnight extends this model with private state elements. This shows how value flows through the system. |
| How apps connect | Web3 explains how wallets, connectors, and dApps communicate with contracts. This shows how users and applications interact with Midnight. |
| How privacy is enforced | Zero-knowledge proofs verify correctness without exposing sensitive data. This shows how private actions stay verifiable. |
| How computation is proved | Kachina is Midnight’s proving system. It converts private computation into verifiable proofs. This shows how we trust execution we cannot see. |
| How it all comes together | ZSwap applies these concepts in practice. It uses private state, proofs, and confidential execution. This shows how a real private dApp works end-to-end. |
Midnight uses zero-knowledge proofs to keep sensitive data private while still verifying contract logic. Its smart contracts combine public on-chain state with private state that stays on your machine, reducing transaction correlation and supporting secure, confidential on-chain atomic swaps of tokens and metadata.
Learn the building blocks
Review circuits, ledgers, and assignments that form Midnight’s foundation.
Explore →Explore Compact contracts
See how Compact defines confidential logic and interacts with verified data.
Open →Keep data private
Learn the patterns that restrict data visibility to authorized participants.
Learn →Understand Compact semantics
Trace how the runtime enforces rules over public and private data.
Read →