Free 30-min Web3 Consultation
Book Consultation
Smart Contract Security Audits
View Audit Services
Custom DeFi Protocol Development
Explore DeFi
Full-Stack Web3 dApp Development
View App Services
Free 30-min Web3 Consultation
Book Consultation
Smart Contract Security Audits
View Audit Services
Custom DeFi Protocol Development
Explore DeFi
Full-Stack Web3 dApp Development
View App Services
Free 30-min Web3 Consultation
Book Consultation
Smart Contract Security Audits
View Audit Services
Custom DeFi Protocol Development
Explore DeFi
Full-Stack Web3 dApp Development
View App Services
Free 30-min Web3 Consultation
Book Consultation
Smart Contract Security Audits
View Audit Services
Custom DeFi Protocol Development
Explore DeFi
Full-Stack Web3 dApp Development
View App Services
LABS
Glossary

Noir

Noir is a domain-specific language (DSL) for writing zero-knowledge circuits that abstracts away low-level cryptographic details, enabling developers to build private applications with a syntax resembling traditional programming.
Chainscore © 2026
definition
PROGRAMMING LANGUAGE

What is Noir?

A domain-specific language for building privacy-preserving applications using zero-knowledge proofs.

Noir is a domain-specific, Rust-inspired programming language designed for creating and verifying zero-knowledge proofs (ZKPs). It abstracts away the complex underlying cryptography, allowing developers to write privacy-preserving logic—known as circuits—using familiar programming constructs like functions, variables, and loops. Noir compiles this high-level code into an intermediate representation that can be proven by different ZK proving systems, such as Barretenberg, making it a versatile and backend-agnostic tool for the ZK ecosystem.

The language's architecture is built around the concept of an oracle, which allows a Noir program to securely request and use external data during proof generation without compromising the proof's integrity. This enables complex real-world applications where private computations must interact with public blockchain state or off-chain data feeds. Noir programs are typically structured into a main function that defines the public and private inputs, the core computational logic, and the constraints that must be satisfied for a valid proof.

A primary use case for Noir is building zkSNARK-based applications on blockchains like Aztec Network, where it is the native smart contract language. Developers use it to create private DeFi transactions, confidential voting systems, and identity attestations. By proving the correctness of a computation without revealing the inputs (e.g., account balances or vote choices), Noir enables a new paradigm of scalable and private on-chain activity.

Noir's toolchain includes nargo, the Noir package manager and command-line tool, which handles project creation, compilation, proof generation (nargo prove), and verification (nargo verify). This integrated development environment, combined with its readable syntax and growing standard library, significantly lowers the barrier to entry for developers entering the zero-knowledge cryptography space, shifting focus from cryptographic implementation to application logic.

The language is actively developed by Aztec Labs and the wider open-source community, with ongoing work to expand its feature set, improve performance, and increase the number of supported proving backends. As a key component of the ZK stack, Noir's evolution is central to realizing scalable, programmable privacy in Web3, making advanced cryptographic techniques accessible to a broader range of software engineers.

etymology
NOIR

Etymology and Origin

The name 'Noir' for the domain-specific language for zero-knowledge proofs is a direct reference to its core technical purpose and aesthetic.

The term Noir is derived from the French word for 'black,' a deliberate choice that evokes the concept of a black box. In cryptography and computer science, a black box describes a system where internal workings are hidden, yet its outputs can be verified—a perfect analogy for a zero-knowledge proof (ZKP). Noir, as a language, allows developers to construct these cryptographic 'black boxes' where the privacy of the input data (the prover's secret) is preserved.

This naming aligns with a tradition in cryptography of using evocative, often dark-themed terminology—such as dark pools in finance or blacklist in security—to conceptually separate public, verifiable outputs from private, hidden inputs. The language's creation by Aztec Network further connects to this theme, as the Aztec protocol was initially focused on providing privacy (or 'darkness') for Ethereum transactions. Thus, Noir linguistically codifies its primary function: to shroud sensitive logic in cryptographic opacity while producing a verifiably correct proof.

The origin of Noir is intrinsically linked to the limitations of existing general-purpose ZKP frameworks. While languages like Circom or libraries such as libsnark offered powerful toolkits, they often required deep cryptographic expertise. Noir was created to abstract this complexity, providing a Rust-inspired syntax that feels familiar to mainstream software developers. Its development was driven by the need to make zk-SNARK and zk-STARK development more accessible, secure, and less error-prone by leveraging a higher-level, intuitive language that compiles down to intermediate representations like ACIR (Aztec's Intermediate Representation).

As a domain-specific language (DSL), Noir's design philosophy emphasizes developer experience and auditability. By choosing a name that immediately conveys its purpose, the creators signaled a shift from niche cryptographic engineering toward a more integrated, pragmatic toolchain for building zk-rollups, private smart contracts, and any application requiring verifiable computation. Its etymology, therefore, is not merely stylistic but a foundational statement about bringing privacy-preserving proofs out of theoretical obscurity and into practical, deployable code.

key-features
NOIR

Key Features

Noir is a domain-specific language (DSL) for writing privacy-preserving zero-knowledge circuits, designed to be accessible and integrate seamlessly with existing development environments.

01

Domain-Specific Language (DSL)

Noir is a domain-specific language purpose-built for writing zero-knowledge proofs (ZKPs). Unlike general-purpose languages, its syntax and tooling are optimized for defining constraint systems and cryptographic primitives, abstracting away the underlying cryptographic complexity. This allows developers to focus on the application logic of their private smart contracts or proofs.

02

ZK Circuit Abstraction

At its core, Noir compiles high-level code into an intermediate representation (ACIR) and ultimately a Rank-1 Constraint System (R1CS), the standard format for ZK-SNARK proofs. This abstraction layer means developers don't write constraints manually; they write logic (e.g., assert(x != y)), and the Noir compiler and backend proof system (like Barretenberg or Marlin) handle the cryptographic transformation.

03

Language Familiarity

Noir's syntax is heavily inspired by Rust, making it familiar to a broad developer audience. It includes common programming constructs like functions, structs, and modules. This design choice significantly lowers the barrier to entry for developers new to zero-knowledge cryptography, as they can leverage existing knowledge of control flow and data structures.

04

Prover & Verifier Generation

A key feature is the automatic generation of the prover and verifier from the same Noir source code. The prover generates a proof that a private computation was executed correctly, while the verifier checks the proof's validity. This automation ensures consistency and eliminates a major source of error in manual cryptographic implementation.

05

Toolchain & IDE Integration

Noir is supported by a robust toolchain including the Noir compiler (nargo), package manager, and testing framework. Crucially, it features a Language Server Protocol (LSP) for rich IDE support (like VS Code), providing syntax highlighting, error checking, and auto-completion. This creates a modern developer experience comparable to working with Solidity or Rust.

06

Proof System Backend Agnosticism

Noir is designed to be backend-agnostic. It uses ACIR as a universal intermediate representation, which can be compiled to different proof system backends (e.g., Barretenberg for ultra-fast proofs, or eventually others like Marlin). This allows the language to evolve independently and leverage advancements in proof system research without breaking developer code.

how-it-works
ZKDSL ARCHITECTURE

How Noir Works

Noir is a domain-specific language (DSL) for creating zero-knowledge proofs, designed to abstract away cryptographic complexity and enable developers to write provable programs using familiar logic.

Noir operates as a high-level language that compiles down to an intermediate representation called ACIR (Abstract Circuit Intermediate Representation). This architecture separates the program's logical constraints from the underlying proof system (e.g., Barretenberg, Gnark). Developers write business logic in Noir's Rust-like syntax, which the compiler transforms into a rank-1 constraint system (R1CS), the mathematical format required for generating zk-SNARKs or zk-STARKs. This decoupling allows the same Noir program to be proven by different backend proving systems, enhancing flexibility and future-proofing.

The development workflow involves three core components: the Noir language for writing circuits, the Noir Proof System (Nargo) toolchain for compiling and proving, and a backend prover to execute the cryptographic heavy lifting. A developer defines private and public inputs, writes assertions about their relationships, and uses Nargo to generate a proof. The resulting proof can be verified by anyone with the correct verification key, confirming the statement's truth without revealing the secret inputs. This makes Noir ideal for applications like private transactions, identity attestations, and verifiable computation off-chain.

A key innovation is Noir's oracle system, which allows circuits to securely request external data during proof generation. Oracles enable proofs about real-world states—such as blockchain history or API responses—by allowing the prover to feed authenticated data into the circuit. Furthermore, Noir supports recursive proofs, where one proof can verify other proofs, enabling scalable zk-rollup constructions. Its standard library provides pre-built cryptographic primitives like hashes and signatures, accelerating development without requiring deep expertise in elliptic curve cryptography.

code-example
NOIR

Code Example

A practical demonstration of Noir, a domain-specific language for creating zero-knowledge proofs, showing its syntax and structure.

A Noir code example typically begins with a fn main() function, which serves as the program's entry point and defines the public inputs, private inputs, and the constraints that constitute the zero-knowledge circuit. For instance, a simple program proving knowledge of a preimage for a hash would declare a public output pub hash and a private input priv preimage, then use a function like std::hash::sha256 to assert the relationship between them with a constraint: assert(std::hash::sha256(preimage) == hash);. This constraint is the core logical statement the prover must satisfy.

The language's syntax is intentionally similar to Rust, providing developers with familiar constructs like functions, mutable variables with let mut, and loops. Noir programs do not execute in a traditional sense; instead, they are compiled into an intermediate representation and then into a proving system-specific format (e.g., for Barretenberg). This process creates the arithmetic circuit that defines the computational statement. Key standard library modules, accessible via use dep::std, provide cryptographic primitives for hashing, signature verification, and field operations essential for building complex business logic privately.

Beyond simple assertions, Noir supports more advanced patterns essential for real-world applications. This includes handling structured data like arrays and structs, implementing conditional logic, and performing operations within a finite field. A common advanced example is a Merkle tree membership proof, where the private input is a secret leaf and a merkle path, and the public input is the root. The code would recursively compute hash pairs up the path and constrain the final result to equal the public root, proving membership without revealing the leaf.

Developing with Noir involves a specific toolchain: the nargo package manager. A typical workflow uses nargo prove to generate a proof from a witness (valid private inputs) and nargo verify to check it against the proving key. Code is organized within a Nargo.toml project file. This ecosystem emphasizes deterministic execution; any non-deterministic operation or external call must be simulated via an oracle, which is an external function that provides data to the circuit during proof generation without being part of the constrained logic itself.

The primary use case for Noir is creating zkSNARKs and zkSTARKs for blockchain applications, particularly within the Aztec Network ecosystem for private smart contracts. However, its agnostic backend design allows it to target different proving systems. This flexibility, combined with its developer-friendly syntax, aims to abstract away the complex cryptography, enabling more engineers to write privacy-preserving applications where the proof validates execution correctness while keeping the inputs confidential.

ecosystem-usage
NOIR

Ecosystem and Usage

Noir is a domain-specific language for creating and verifying zero-knowledge proofs, designed for integration within broader blockchain ecosystems. Its primary use cases include privacy-preserving applications and scalable verification.

02

Proving Backends & Verification

Noir circuits are backend-agnostic. They can be executed and proven using different proof systems, enabling flexibility and optimization.

  • Barretenberg: A high-performance UltraPlonk proof system, often used for development and testing.
  • Groth16: A widely recognized and succinct proof system used for production verification on Ethereum. The verifier contract, often generated automatically, is a smart contract that checks the proof's validity on-chain.
03

Primary Use Case: Private Smart Contracts

Noir enables private state and logic on public blockchains. Developers write the private logic in Noir, which generates a ZKP that a computation was performed correctly without revealing the inputs. This is foundational for:

  • Private voting and governance.
  • Confidential DeFi transactions (e.g., hiding trade amounts).
  • Identity attestations without exposing personal data.
05

Tooling: Nargo and NoirJS

The ecosystem provides essential tools for development:

  • Nargo: The command-line tool for managing Noir projects, compiling circuits, generating proofs, and creating verifier contracts.
  • NoirJS: A JavaScript/TypeScript library that allows generating and verifying proofs directly in a browser or Node.js environment, enabling client-side proof generation for web applications.
06

Standard Library and Oracles

Noir includes a standard library (std) with common cryptographic primitives and utilities like hashing (sha256, pedersen), signatures, and merkle tree operations. A key feature is support for oracles, which allow Noir circuits to securely request and use off-chain data (e.g., price feeds) within a private computation, verified by the proof.

examples
NOIR

Example Applications

Noir is a domain-specific language for writing privacy-preserving zero-knowledge circuits. These applications showcase how Noir enables developers to build verifiable, private logic for the blockchain.

COMPARISON

Noir vs. Other ZK Languages

A technical comparison of Noir's design and features against other prominent zero-knowledge proof programming languages.

Feature / MetricNoirCircomCairo

Primary Design Goal

High-level, developer-friendly ZK apps

Circuit design for custom proving systems

General-purpose computation for validity rollups

Language Paradigm

Domain-specific language (DSL), Rust-like

Circuit description language

Turing-complete assembly-like

Standard Library & Abstraction

High-level (e.g., std::crypto)

Low-level, requires manual circuit logic

Mid-level, with built-in Cairo OS primitives

Proving System Agnostic

Backend Proving Systems Supported

Barretenberg, Gnark, Marlin

Groth16, Plonk (via snarkjs)

SHARP, Stone, Plonk

Primary Use Case

Application logic in private smart contracts

Custom cryptographic circuits & tooling

Layer 2 validity proof construction

Developer Onboarding

Simpler for traditional software developers

Requires cryptographic circuit knowledge

Steeper learning curve, unique architecture

Native Integration Target

Ethereum & EVM chains (via Aztec)

Multiple blockchains (Ethereum-centric)

Starknet & StarkEx L2 systems

security-considerations
NOIR

Security Considerations

Noir is a domain-specific language for writing zero-knowledge proofs, where security depends on correct circuit design, cryptographic backend selection, and rigorous verification.

01

Circuit Logic & Constraint Correctness

The primary security risk in Noir is an incorrectly implemented circuit. A bug in the constraint logic can create a soundness error, allowing a prover to generate a valid proof for a false statement. This requires:

  • Formal verification of critical circuits.
  • Extensive unit and integration testing, including edge cases.
  • Independent audits of the ZK circuit code, separate from the application logic.
02

Cryptographic Backend & Trusted Setup

Noir can compile to different proof systems (e.g., Barretenberg, Gnark). Security depends on:

  • The cryptographic assumptions (e.g., discrete log, elliptic curve security) of the chosen backend.
  • Whether a trusted setup (a.k.a. Structured Reference String) is required. Some backends use a universal, updatable setup, while others may require a new, potentially toxic waste-generating ceremony per circuit.
  • The correct implementation of the backend prover and verifier algorithms.
03

Input Validation & Oracles

Noir circuits often rely on external data via oracles. Security failures here break the proof's integrity.

  • Oracle Authenticity: The prover must cryptographically verify that input data (e.g., a blockchain state root) is genuine and not fabricated.
  • Input Range Checks: Constrain all public and private inputs to expected ranges to prevent overflows or underflows that could break logic.
  • Determinism: Oracle calls and any non-deterministic hints must be carefully managed to ensure proof reproducibility.
04

Side-Channel & Privacy Leakage

While ZK proofs hide private inputs, improper design can leak information.

  • Deterministic Provenance: If a proof's structure or timing is unique to a specific private input, it can act as a fingerprint.
  • Public Input Correlation: Even with a valid proof, sensitive information can be inferred from the public inputs and outputs if the application logic is not privacy-preserving by design.
  • Prover Environment: The machine generating the proof must be secure to prevent extraction of private witness data during computation.
05

Verifier Contract Security

On-chain verification involves a smart contract that checks the proof. Critical considerations include:

  • Correct Verifier Deployment: The contract must use the exact verification key generated for the specific compiled circuit.
  • Gas Limit Robustness: Verification must complete within block gas limits; complex proofs may be prohibitively expensive.
  • Front-running & Replay Attacks: The application layer must ensure proofs are submitted and used only once for their intended purpose.
06

Toolchain & Dependency Risks

The security of a Noir application depends on its entire toolchain.

  • Compiler Integrity: A compromised nargo compiler could introduce vulnerabilities during circuit compilation.
  • Standard Library Audits: The security of common functions (e.g., hashing, signatures) in noir_stdlib must be verified.
  • Upgrade Risks: Changes to the Noir language, compiler, or backend can introduce breaking changes or new vulnerabilities, requiring re-audits.
NOIR

Common Misconceptions

Noir is a domain-specific language for writing zero-knowledge proofs, but its capabilities and relationship to other technologies are often misunderstood. This section clarifies frequent points of confusion.

Noir is neither a blockchain nor a zkVM; it is a domain-specific language (DSL) and a compiler framework for creating zero-knowledge proofs. Noir allows developers to write circuits for arithmetic circuits in a high-level, Rust-like syntax, which it then compiles into a format compatible with various proof systems like Barretenberg, Halo2, or Plonk. A zkVM (zero-knowledge virtual machine) like RISC Zero or SP1 executes arbitrary programs and generates proofs of that execution, whereas Noir is designed for writing custom, optimized circuits for specific logic. It is a tool for building zkVM applications or standalone ZK applications, not a runtime environment itself.

NOIR

Frequently Asked Questions

Essential questions and answers about Noir, a domain-specific language for building zero-knowledge proofs.

Noir is a domain-specific language (DSL) for writing and verifying zero-knowledge proofs (ZKPs). It works by allowing developers to write provable programs in a Rust-like syntax, which are then compiled into an intermediate representation and ultimately into a ZK circuit. Noir abstracts away the underlying cryptographic complexity, enabling developers to focus on business logic. The language is agile proof system agnostic, meaning it can compile proofs to be verified by different backend proving systems like Barretenberg or other SNARK/STARK frameworks. A Noir program defines constraints that a prover must satisfy to generate a valid proof, which a verifier can check without learning the private inputs.

ENQUIRY

Get In Touch
today.

Our experts will offer a free quote and a 30min call to discuss your project.

NDA Protected
24h Response
Directly to Engineering Team
10+
Protocols Shipped
$20M+
TVL Overall
NDA Protected Directly to Engineering Team