Skip to main content
Version: v4.0.0-nightly.20260210

Aztec.js

Aztec.js is a library that provides APIs for managing accounts and interacting with contracts on the Aztec network. It communicates with the Private eXecution Environment (PXE) through a PXE implementation, allowing developers to easily register new accounts, deploy contracts, view functions, and send transactions.

Installing

npm install @aztec/aztec.js@4.0.0-nightly.20260210

Common Dependencies

Most applications will need additional packages alongside @aztec/aztec.js, e.g.:

npm install @aztec/aztec.js@4.0.0-nightly.20260210 \
@aztec/accounts@4.0.0-nightly.20260210 \
@aztec/test-wallet@4.0.0-nightly.20260210 \
@aztec/noir-contracts.js@4.0.0-nightly.20260210
PackageDescription
@aztec/aztec.jsCore SDK for contracts, transactions, and network interaction
@aztec/accountsAccount contract implementations (Schnorr, ECDSA)
@aztec/test-walletSimplified wallet for local development and testing
@aztec/noir-contracts.jsPre-compiled contract interfaces (Token, NFT, etc.)

Package Structure

@aztec/aztec.js uses subpath exports. You must import from specific subpaths rather than the package root:

import { createAztecNodeClient, waitForNode } from "@aztec/aztec.js/node";
import { Fr } from "@aztec/aztec.js/fields";
import { AztecAddress } from "@aztec/aztec.js/addresses";

AI-Friendly Reference

The TypeScript API reference links to markdown interface files for common packages for easy use with AI coding assistants. Copy relevant sections to give your AI tool accurate context about Aztec.js APIs.

Guides