Skip to main content

Nonce

Type-safe transaction nonces for Ethereum transaction ordering and replay protection.

Overview

Branded bigint type representing a transaction nonce. Nonces are sequential counters that ensure transactions from an account are processed in order and prevent replay attacks. Each account has a nonce that increments with each transaction.

Quick Start

How Nonces Work

Every Ethereum account has a nonce that:
  1. Starts at 0 for new accounts
  2. Increments by 1 with each transaction sent
  3. Must be used exactly once (no gaps, no reuse)
  4. Determines transaction ordering from an account

API Reference

Constructors

Conversions

Operations

Use Cases

Sequential Transaction Sending

Transaction Replacement (Speed Up / Cancel)

Pending Transaction Detection

Common Issues

Nonce Too Low

Nonce Gap

Concurrent Transactions

References