x402
  • Welcome to x402
  • x402 Landing Page
  • CDP's x402 Docs
  • FAQ
  • Getting Started
    • Quickstart for Buyers
    • Quickstart for Sellers
  • Core Concepts
    • HTTP 402
    • Client / Server
    • Facilitator
    • Wallet
  • Guides
    • MCP Server with x402
Powered by GitBook
On this page
  • What is HTTP 402?
  • Why x402 Uses HTTP 402
  • Summary
  1. Core Concepts

HTTP 402

PreviousQuickstart for SellersNextClient / Server

For decades, HTTP 402 Payment Required has been reserved for future use. x402 unlocks it, and .

What is HTTP 402?

is a standard, but rarely used, HTTP response status code indicating that payment is required to access a resource.

In x402, this status code is activated to:

  • Inform clients (buyers or agents) that payment is required.

  • Communicate the details of the payment, such as amount, currency, and destination address.

  • Provide the information necessary to complete the payment programmatically.

Why x402 Uses HTTP 402

The primary purpose of HTTP 402 is to enable frictionless, API-native payments for accessing web resources, especially for:

  • Machine-to-machine (M2M) payments (e.g., AI agents).

  • Pay-per-use models such as API calls or paywalled content.

  • Micropayments without account creation or traditional payment rails.

Using the 402 status code keeps x402 protocol natively web-compatible and easy to integrate into any HTTP-based service.

Summary

HTTP 402 is the foundation of the x402 protocol, enabling services to declare payment requirements directly within HTTP responses. It:

  • Signals payment is required

  • Communicates necessary payment details

  • Integrates seamlessly with standard HTTP workflows

absolves the internet of its original sin
HTTP 402