Skip to content

What Is x402? How AI Agents Pay With Stablecoins

By Vault Capital Team·Published on ·Updated on ·10 min read·Also available in Português

What is x402 is the question of anyone who has seen the name next to "AI agents", "payments" and "Coinbase" and wants to understand what sits behind it. x402 is an open standard that uses an old web code, HTTP 402 "Payment Required", so that a website or API can charge for each request and get paid on the spot, in stablecoins, with no sign-up, subscription or checkout page. The payer can be a person, but the use case the standard has in mind is a program, such as an AI agent that buys data or services on its own. This post explains, from the official documentation and company announcements read on 25 November 2026, how x402 works, who governs it, how much it already moves and the question that matters for anyone holding crypto: who holds the key to the agent's wallet.

In short

  • x402 uses the HTTP 402 code, which the web specification leaves "reserved for future use", to charge inside the request itself: the server asks for payment, the client signs and retries.
  • Coinbase published the whitepaper on 6 May 2025. The protocol moved to the x402 Foundation, announced on 2 April 2026 by the Linux Foundation, a nonprofit that hosts open-source projects, and operating since 14 July 2026, with 40 members.
  • USDC is the most common asset, but the protocol accepts any Ethereum-compatible network, plus Solana and other ecosystems.
  • Per the x402scan dashboard, there were 7.4 million transactions in the 30 days to 25 November 2026, with 41,644 buyers.
  • In Coinbase's official example, the agent's key sits in a secure environment at Coinbase, operated by the developer's credentials. Payments are irreversible.
Term What it is What it is not
HTTP 402 The web code for "payment required" A new code created by x402
PAYMENT-REQUIRED The server's reply with price, network and destination A charge already made
PAYMENT-SIGNATURE The signed payment the client sends Access to the client's wallet
Facilitator A service that verifies and settles the payment on chain A custodian: it holds no funds
x402 Foundation The Linux Foundation body that governs the standard A company or a token

The code that was reserved

Every website response carries a code: 200 when it worked, 404 when the page does not exist. The 402 code has been on the list since the early web standards, and the current specification, RFC 9110 from June 2022, says only: "The 402 (Payment Required) status code is reserved for future use." There was never a standard way to pay from it.

That does not mean the code goes unused. Cloudflare wrote on 23 September 2025 that sites on its network send "over a billion HTTP 402 response codes to bots and crawlers" per day, as a paid-access notice. What was missing was the next step: the bot being able to pay and get the content in the same exchange. That is the step x402 standardises. The documentation sums it up: "x402 is an open, neutral standard for internet-native payments."

How it works, step by step

In the current version of the protocol, called V2, the exchange happens through three headers:

  1. The client requests a resource, such as an API response or a file.
  2. If there is no payment, the server replies 402 with a PAYMENT-REQUIRED header stating the price, the network and the destination address.
  3. The client signs a payment with its own wallet and retries the request with a PAYMENT-SIGNATURE header. The documentation explains that this header proves the client "authorized payment".
  4. The server checks the payment, on its own or through a facilitator, the transaction is settled on the blockchain, and the resource comes back with a PAYMENT-RESPONSE header.

The facilitator is the piece that tends to confuse people. Per the documentation, it is an "optional but recommended" service that verifies and settles payments, and "The facilitator does not hold funds or act as a custodian". Because the buyer signs the payment, a facilitator that tampered with the transaction would fail the signature check. There are three charging schemes: a fixed amount, a cap with billing for actual usage, and a deposit scheme settled in batches.

There is no protocol fee, but there is a cost: network gas (the fee each blockchain transaction pays) and, at some facilitators, a fee. Coinbase's, for example, states that the first 1,000 transactions a month are free and each one after that costs US$0.001, a price read on 25 November 2026.

Alerts on DeFi and stablecoins

An e-mail when something changes on this topic: new rules, deadlines, scams going around and Vault news.

Which networks and currencies

x402 charges in tokens that already exist, not in a token of its own. Per the documentation's networks page, read on 25 November 2026, the protocol accepts any Ethereum-compatible network and ecosystems such as Solana, TON, Stellar, Algorand, Aptos, NEAR, XRPL, Cardano and Sui, and on Ethereum-compatible networks it accepts any ERC-20 token. In practice, USDC is "the most common asset", per Coinbase, and the default asset on Base, the network created by Coinbase. What a stablecoin is and why it works for payments is in What are stablecoins: USDT vs USDC for investors in Brazil.

Google shows searches such as "x402 token" and "x402 price". The documentation we read describes no protocol token, and tokens trading under that name are third-party.

Who created it and who governs it

x402 was born at Coinbase, which published the whitepaper on 6 May 2025, promising to eliminate "the need for API keys, subscriptions, and manual payment processing". The standard then left the company in three steps:

  • 23 September 2025: Cloudflare announced it was "partnering with Coinbase to create the x402 Foundation".
  • 2 April 2026: the Linux Foundation announced the launch of the x402 Foundation, with Coinbase contributing the protocol and initial backing from companies such as Visa, Mastercard, Google, AWS, Stripe, Shopify and Circle.
  • 14 July 2026: the foundation began operating, the contribution was completed, and "40 organizations have joined as members".

The official code repository also moved: Coinbase's became a "development fork" of the foundation's repository. The documentation says that to use x402 "you don't need any Coinbase products".

Who uses it, and how much

Adoption announcements come from the companies themselves. Cloudflare said on 23 September 2025 that agents built with its kit "can now pay for resources with x402". Google, when launching its agent payments protocol AP2 on 16 September 2025, announced an x402 extension "for agent-based crypto payments". The Solana Foundation stated in April 2026 that the network accounted for "nearly 65% of x402 transaction volume this year". Being a foundation member, like Visa or Mastercard, shows support for the standard, not production use.

The numbers vary by source:

  • Coinbase: more than 100 million x402 payments and US$28 million in volume through its facilitator, on Base and Solana, with no cut-off date on the page.
  • x402scan dashboard, 30 days to 25 November 2026: 7,408,323 transactions, 41,644 buyers and 14,457 sellers. The raw volume, if measured in USDC, comes to about US$1.87 million by our conversion, an average of around US$0.25 per transaction.

In other words: many small payments, which fits the goal of charging cents per request.

Who holds the agent's key

For an AI agent to pay, someone needs a key that signs. In Coinbase's official example, the agent uses "a CDP-managed wallet, so there is no private key to store anywhere" (CDP is Coinbase's developer platform): the key sits in a trusted execution environment (TEE) at Coinbase, and the developer controls the access credentials that operate the wallet. The documentation describes these wallets as "Developer-controlled. Your service controls the API credentials and can operate the wallet." The protocol documentation notes that buyers can also sign locally with common wallet libraries.

Three warnings from the documentation itself help frame the risk:

  • Payments are irreversible: for the fixed-amount (exact) and capped (upto) schemes, "Payments made with exact or upto are irreversible once settled, so there are no chargebacks."
  • Spending limits are the buyer's setting: Coinbase's client accepts a cap per payment and per period, but "Spend controls are TypeScript only", meaning the limits work only in the library for the TypeScript programming language.
  • A catalogue is not a seal: about the list of paid services, "Treat the Bazaar as a catalog, not an endorsement."

What this changes for anyone holding crypto

An agent with a wallet is a hot wallet run by software. The same rule as any hot wallet applies: only the amount needed for the job, separate from your wealth, with a limit set and never the same key or seed as your long-term reserve. The logic is in Hot wallet vs cold wallet: which to use for each amount. Agent wallets also connect to Ethereum's smart accounts, explained in Passkey Crypto Wallets: Smart Accounts on Ethereum Explained.

What to check before using it

  1. Who holds the agent's key: you, in a local wallet, or a provider.
  2. The spending limit per payment and per period, and whether it is switched on.
  3. Which network and token the service charges in.
  4. Who the facilitator is and whether it charges a fee.
  5. How much balance the agent's wallet needs, and only that in it.

The other topics in this series are in Crypto Technology Glossary: x402, NFTs, Lightning and More.

Crypto assets carry high risk, including significant volatility and the possibility of losing the capital invested, and no form of custody changes that. Vault Capital is a securities consultancy authorized by the CVM under CVM Resolution 19/2021 and works on the principle of advice, never custody: assets stay on the client's own exchanges and wallets. If you want to set up your own wallet with hands-on guidance, the Self-Custody Immersion is built for that, and the FAQ explains how Vault works without custody of client assets.

Frequently asked questions

What is x402?

An open internet payments standard that uses the HTTP 402 "Payment Required" code. The server replies with the price, the client signs a stablecoin payment and retries, and access is granted after settlement on the blockchain. It was designed for APIs and AI agents that pay per use.

Does x402 belong to Coinbase?

It was born at Coinbase, which published the whitepaper on 6 May 2025, but it is now governed by the x402 Foundation at the Linux Foundation, operating since 14 July 2026 with 40 members. The documentation says no Coinbase product is needed to adopt the standard.

Does x402 have its own token?

The documentation we read describes no protocol token. Payments are made in existing tokens, mainly USDC, and the standard accepts any ERC-20 token on Ethereum-compatible networks. Tokens named x402 on exchanges are third-party.

How much does x402 cost to use?

The protocol charges no fee. There is network gas and, at some facilitators, a fee: Coinbase's listed, on 25 November 2026, 1,000 free transactions a month and US$0.001 per transaction after that.

Can an x402 payment be reversed?

No. Coinbase's documentation says payments settled under the fixed-amount and capped schemes are irreversible, with no chargebacks. That is why the spending limit and the agent wallet's balance are the main protection.

In Brazil, is paying for a service with USDC taxable?

Brazil's tax authority treats paying for goods or services with crypto as a disposal of the crypto used. With a stablecoin the gain is usually close to zero, but the operation exists; the general rule is in Does Swapping Crypto Trigger Tax in Brazil? USDT, Swaps.

Let's talk

An agent that pays on its own is a hot wallet in a program's hands, and the usual question still applies: who has the key. If you want to learn to set up and test your own wallet safely, Vault's Self-Custody Immersion teaches the process hands-on, in person, with the setup validated by a specialist.

Want to hold your crypto safely, on your own?

Vault's Self-Custody Immersion teaches wallets, seed backups and succession planning, hands on.

Learn about the Immersion

Path · DeFi and stablecoins

Start the DeFi and stablecoins path

What is DeFi: uses, real risks and the rules in Brazil

What is DeFi: how decentralized finance replaces the intermediary with code, where the money sits, the risks with a named example and what Brazil requires.