x402 is an open, HTTP-native payment protocol designed to enable programmatic, real-time payments directly within standard web requests. It repurposes the long-unused HTTP 402 “Payment Required” status code to allow servers to request payment before delivering content or API responses. The protocol supports multiple payment networks, including blockchain-based systems and fiat-compatible facilitators, making it flexible and network-agnostic. It is particularly suited for machine-to-machine transactions, such as AI agents paying for APIs, data, or compute resources without human intervention. The system eliminates the need for accounts, sessions, or traditional payment rails by using cryptographic authorization and wallet-based transactions. Developers can integrate payment requirements into endpoints with minimal code using middleware and SDKs. Overall, x402 introduces a new economic layer to the web, enabling micropayments and pay-per-use services natively over HTTP.

Features

  • HTTP-native payment flow using 402 status code
  • Support for crypto and multi-network payment schemes
  • Programmatic payments for APIs and AI agents
  • No accounts or session-based authentication required
  • Middleware and SDK integration for developers
  • Micropayment and pay-per-use service enablement

Project Samples

Project Activity

See All Activity >

Categories

Cryptocurrency

License

Apache License V2.0

Follow x402

x402 Web Site

Other Useful Business Software
$300 Free Credits for Your Google Cloud Projects Icon
$300 Free Credits for Your Google Cloud Projects

Start building on Google Cloud with $300 in free credits. No commitment, no credit card required until you're ready to scale.

Launch your next project with $300 in free Google Cloud credits—no strings attached. Test, build, and deploy without risk. Use your credits across the entire Google Cloud platform to find what works best for your needs. After your credits are used, continue with always-free tier services. Only pay when you're ready to scale. Sign up in minutes and start exploring.
Start Free Trial
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of x402!

Additional Project Details

Programming Language

TypeScript

Related Categories

TypeScript Cryptocurrency Software

Registered

2026-04-29