Welcome to x402
This guide will help you understand x402, the open payment standard, and help you get started building or integrating services with x402.
x402 is the open payment standard that enables services to charge for access to their APIs and content directly over HTTP. It is built around the HTTP 402 Payment Required
status code and allows clients to programmatically pay for resources without accounts, sessions, or credential management.
With x402, any web service can require payment before serving a response, using crypto-native payments for speed, privacy, and efficiency.
Why Use x402?
x402 addresses key limitations of existing payment systems:
High fees and friction with traditional credit cards and fiat payment processors
Incompatibility with machine-to-machine payments, such as AI agents
Lack of support for micropayments, making it difficult to monetize usage-based services
Who is x402 for?
Sellers: Service providers who want to monetize their APIs or content. x402 enables direct, programmatic payments from clients with minimal setup.
Buyers: Human developers and AI agents seeking to access paid services without accounts or manual payment flows.
Both sellers and buyers interact directly through HTTP requests, with payment handled transparently through the protocol.
What Can You Build?
x402 enables a range of use cases, including:
API services paid per request
AI agents that autonomously pay for API access
Paywalls for digital content
Microservices and tooling monetized via microtransactions
Proxy services that aggregate and resell API capabilities
How Does It Work?
At a high level, the flow is simple:
A buyer requests a resource from a server.
If payment is required, the server responds with
402 Payment Required
, including payment instructions.The buyer prepares and submits a payment payload.
The server verifies and settles the payment using an x402 facilitator's /verify and /settle endpoints.
If payment is valid, the server provides the requested resource.
For more detail, see:
Client / Server
Facilitator
HTTP 402
Roadmap
x402 is designed as an open standard, and we're excited to build x402 alongside our community. Some items in the roadmap we're excited about include:
The goal is to make programmatic commerce accessible, permissionless, and developer-friendly.
Get Started
Ready to build? Start here:
Last updated