As the internet evolves toward autonomous agents, AI-native services, and on-demand infrastructure, a critical missing piece is a standardized, seamless payment layer. Enter x402—a protocol that revives HTTP status code 402 (“Payment Required”) to enable a web-native, chain-agnostic way to handle digital payments between clients and servers.
Originally championed by Coinbase, x402 is now gaining momentum as a core building block for the next generation of internet-native commerce. Backed by open infrastructure providers like Cloudflare and governed by the newly formed x402 Foundation, this protocol is poised to redefine how machines, users, and agents exchange value online.
What is x402?
x402 is an open protocol for request-level payments over HTTP. It allows servers to price specific endpoints or actions. It enables clients to respond with a signed payment header, facilitating real-time settlement without the need for prior onboarding, API keys, or subscriptions.
Key characteristics:
- 🔁 HTTP-native: Uses standard request/response structure with status code 402 to indicate payment is required
- ⚙️ Token-agnostic: Built to work across multiple payment rails (starting with USDC)
- 🧩 Composable: Works alongside protocols like ATXP (Agent Transaction Protocol) and AP2 (authorization primitives)
- 💡 Designed for agents: Enables autonomous software, crawlers, and bots to access paid resources
With this protocol in place, software systems can handle payments between each other—whether they’re pulling data from an API, crawling a site, tapping into compute power, or unlocking restricted content.
Why It Matters
Traditional payment infrastructure isn’t designed for autonomous agents or real-time pay-per-use pricing. Stripe and credit card-based APIs rely on heavy identity verification, subscriptions, and human oversight. That’s a problem in a world increasingly run by autonomous agents and modular services.
x402 solves this by:
- Allowing fine-grained monetization of resources (e.g., $0.001 per request)
- Requiring no pre-established relationship between client and server
- Operating over familiar protocols (HTTP, headers, JSON)
- Providing finality and transparency via on-chain settlement
This is particularly relevant in the context of AI agents, which need to interact with APIs, tools, and content sources programmatically—and often without human intervention.
How It Works
- Client makes a request to a protected endpoint (e.g., premium-content)
- Server responds with 402 Payment Required, including pricing metadata (amount, asset, payTo, etc.)
- Client prepares a signed payment (e.g., ERC-3009 TransferWithAuthorization)
- Client re-sends the request with an X-PAYMENT header containing the signed payment
- Server verifies and settles the payment, then returns a 200 response and includes an X-PAYMENT-RESPONSE receipt
The payment process can be handled by the server directly or through a facilitator that manages wallet infrastructure, authorization, and settlement.

Cloudflare’s Role in x402: Infrastructure, Innovation, and Open Governance
In July 2025, Cloudflare formally backed x402, integrating support across its infrastructure and joining Coinbase in advancing it as an open, collaborative internet standard—one that could serve as a foundation for payments between services, agents, and APIs.
Founding the x402 Foundation
Cloudflare has joined Coinbase in launching the x402 Foundation, a neutral body that will:
- Maintain and evolve the x402 specification
- Promote adoption across the developer ecosystem
- Ensure chain-agnostic and wallet-agnostic implementation flexibility
- Define open governance to prevent centralization or vendor lock-in
This signals Cloudflare’s intent to treat x402 not as a product, but as a foundational internet primitive, much like DNS or TLS.
Native Agent Support: Agents SDK + MCP
Cloudflare has embedded x402 into its Agents SDK and Model Communication Protocol (MCP) infrastructure, enabling AI agents to:
- Dynamically interact with paid APIs and services
- Sign or authorize payments directly
- Settle transactions as part of their runtime workflows
For ecosystems built around AI agents, the ability to pay per use—for data access, tool execution, or inference APIs—is a major advantage.
Deferred Payment Extension
To address the inefficiencies of real-time micro-settlement, Cloudflare proposed a deferred-payment extension to x402. This allows:
- Session-based aggregation of multiple small requests
- Flexible settlement timing, such as payment at the end of a usage period
- Trust-model flexibility, with support for facilitators and asynchronous flows
Pay-as-you-go access to data, tools, and inference endpoints gives AI-driven systems the flexibility they need to scale without overcommitting to fixed costs.
Multi-Scheme & Fallback Support
Cloudflare’s implementation supports multiple payment Requirement objects in a single 402 response. This allows:
- Clients to choose among supported chains and tokens
- Fallback behavior when a preferred scheme isn’t available
- Compatibility with evolving protocols like AP2 and ATXP
By embedding these capabilities directly into its edge infrastructure, Cloudflare makes it significantly easier for developers to adopt and scale x402-based payment logic.
👋 What part of your product are you looking to monetize with x402?
We’ll use your answer to tailor the right implementation strategy.
Trusted by tech leaders at:



Real-World Use Cases
- Pay-per-API Access – Monetize high-value endpoints on a per-call basis
- Autonomous Crawlers – Charge bots and agents for crawling, indexing, or data extraction
- AI Tool Access – Enable agents to trigger paid tools or services (e.g., image generation, translation, or compute)
- Session-Based Billing – Aggregate usage into a single deferred payment
- Content Monetization – Use x402 paywalls to restrict premium reports, dashboards, or datasets
Benefit
✅ Frictionless Onboarding – No user registration or credit card forms
✅ On-Chain Settlement – Transparent, auditable, and tamper-proof
✅ Supports Microtransactions – Efficient down to fractions of a cent
✅ Chain & Wallet Flexibility – Future-proof across networks and tokens
✅ Agent-Native – Designed for machine and human users alike
✅ Open & Interoperable – Governed by the x402 Foundation and extensible with ATXP/AP2
Implementation Checklist
✅ Identify endpoints to monetize (e.g., /generate, /crawl, /premium)
✅ Define pricing models (fixed per-call, tiered, or deferred)
✅ Choose initial payment rail (e.g., USDC on Base or Ethereum)
✅ Integrate a facilitator or server-side middleware for payment verification
✅ Build agent or client logic to handle 402 responses and sign payments
✅ Implement monitoring, receipts, and error handling
✅ Plan for chain diversity, fallback behavior, and compliance controls
x402 vs Traditional Web Payment Methods
Developer Experience
import { paymentMiddleware } from 'x402';
app.use(paymentMiddleware('0xMerchantAddress', {
'/api/premium': '$0.005',
}))
On the client side, just attach a signed X-PAYMENT header using the helper library. Coinbase’s facilitator will verify the transaction, settle it, and return a receipt that the server can trust.
You can test this now on the Base Sepolia testnet with real pricing flows and dashboards.
Where Curotec Comes In
Whether you’re looking to monetize an API, explore machine-to-machine commerce, or prototype an AI-native checkout experience, Curotec can help you implement x402 with confidence.
Here’s how:
We’ve helped fintechs and SaaS providers architect blockchain-based solutions, and we’re tracking closely with the x402 ecosystem. As facilitator options and token support expand, we’ll help you scale securely.
Implementation Checklist
✅ Identify monetizable endpoints (e.g., /generate, /download, /stream)
✅ Set a pricing model: flat fee, tiered access, or metered usage
✅ Choose which tokens you’ll accept (USDC at launch)
✅ Decide on your facilitator or self-hosted settlement model
✅ Engage a partner like Curotec to scope your pilot and bring it to life
Curotec can help you implement x402
Turn your endpoints into revenue streams. From strategy to code to compliance, we’ll help you make x402 work for your business.
→ Schedule a discovery call today.