Dec 15, 2025

What is x402?

What is x402?

x402 is an open standard payment protocol for the web. It utilizes the long-reserved HTTP 402 status code (”payment required”) and signals that a payment must be made before accessing a resource (e.g., website, API, data).

x402 is blockchain-agnostic, allowing payments using stablecoins over any compatible chain. It’s not tied to one specific blockchain. The protocol is intended to support micropayments and AI agent payments. We think x402 will be especially useful for data access like agents paying for premium API calls.

The x402 specification

The x402 payment protocol is managed as an open specification originally developed and published by Coinbase and now stewarded by the x402 community. There are now two versions of the specification. Version 2 was recently released on December 11. The specification describes the protocol’s payment scheme and facilitator interface. A facilitator service verifies payment payload and settles the payment on the blockchain.

What problems does x402 solve?

x402 solves the fragmentation of crypto payments by giving wallets, merchants, and apps a universal, chain-agnostic way to request, describe, route, and settle payments.

Crypto payments today are fragmented across chains, wallets, and transaction formats, making it difficult for merchants and developers to support payments without building multiple integrations.

x402 solves this by defining a universal, chain-agnostic way to request and describe a payment. x402 packages the recipient, amount, asset, chain options, and structured metadata into a standardized, machine-readable payment request, which makes it useful for AI agents.

Because x402 is settlement-agnostic, wallets can route the payment through the best available option—whether that’s the user’s preferred chain, the lowest-fee chain, or a cross-chain transfer—while still satisfying the merchant’s requirements. This makes crypto payments feel more like universal digital payments instead of a patchwork of incompatible protocols.

How x402 works

Here is a step-by-step of what happens when a client (e.g., AI agent) tries to access a resource protected by x402. This list is based on version 1 of the specification.

  1. Client sends HTTP request to a resource server (e.g., website, API) that has x402 enabled.

  2. Server responds with “402 Payment Required”, along with a JSON body describing payment requirements (how much, which token, which chain/address).

  3. Client constructs a signed payment payload, using their crypto wallet and cryptocurrency (e.g. stablecoin on a blockchain).

  4. Client retries the request, this time including the payment payload in a standardized HTTP header called X-PAYMENT.

  5. Server verifies the payment via a facilitator service, confirming that the on-chain payment took place.

  6. Once verified, the server returns the requested resource, along with a X-PAYMENT-RESPONSE header containing transaction details.

How does the facilitator work within the x402 protocol?

In the x402 protocol, a facilitator is the off-chain service (usually operated by a business, app, or wallet provider) that coordinates, validates, and submits the payment action to the blockchain on behalf of the payer.

Think of x402 as an HTTP request that triggers an on-chain action. The facilitator is the piece of infrastructure that:

  1. Receives the payment request.

  2. Validates it (schema, signatures, permissions, amounts).

  3. Constructs the actual transaction on the target chain.

  4. Executes it (directly or via a paymaster/gas sponsor).

  5. Returns an authoritative result back to the requester.

It’s the glue between the simple x402 request and the complex on-chain execution.

SBC facilitator demo

We created a demo of a multi-chain facilitator that uses SBC for an agentic payment. The demo shows how three services interact to make an x402 payment work. These services include (1) a facilitator, (2) a hypothetical premium API, and (3) an AI agent that makes the payment.

If you’re looking to incorporate x402, please reach out on Telegram and let us know about your project. We’d love to help build tools to enable seamless x402 payments.

Join the SBC

ecosystem

Partner with us to build a global, free, and accessible payment network.

Join the SBC

ecosystem

Partner with us to build a global, free, and accessible payment network.

Join the SBC

ecosystem

Partner with us to build a global, free, and accessible payment network.

Join the SBC

ecosystem

Partner with us to build a global, free, and accessible payment network.