Cloudflare has begun making Monetization Gateway available in a closed beta, with the goal of enabling domain owners to charge AI agents for access to websites, APIs, MCP tools, and datasets. The current phase is available to eligible sellers and buyers in the United States, while the company says support for additional geographies will come later.
The core idea is to shift payment from a subscription or prepaid-credit model to one that bills the agent for the consumption unit itself, such as each request, search, or token. Instead of redirecting the customer to a separate payment page, the system uses the HTTP 402 Payment Required status code to send payment instructions within the request cycle for the resource itself.
How does the gateway work?
The seller specifies which requests require payment, their price, and the party that will receive the funds. When access is attempted, the buyer receives payment instructions, then signs the authorization, and the resource is delivered after settlement is completed. Cloudflare enables the creation of pricing rules based on parts of the request, such as the URL, headers, and query parameters, with support for fixed or variable pricing.
The gateway handles payment verification and settlement through Coinbase x402 Facilitator, as well as failure handling, retries, analytics, and changes to the x402 protocol. Settlement takes place on the Base network using USDC, which is pegged to the U.S. dollar. Cloudflare later plans to add agent-side service discovery, transaction logs, additional payment methods, and identity mechanisms.
Four production use cases
- Cloudflare AI Gateway: Cloudflare customers in the United States can pay for on-demand inference for specific models, using the PAYMENT-METHOD: x402 header instead of relying exclusively on a prepaid credit balance. The gateway supports pricing sourced from AI Gateway itself, allowing the token-count-based pricing engine to be used.
- Ceramic.ai: The search engine, which contains an index of more than 40 billion pages and returns results in less than 50 milliseconds, uses fixed pricing that enables searches to be performed without an API key.
- Stocktwits: The company enables AI agents to request market indicators, such as sentiment, message volume, follower counts, and trending stocks, while charging for each request. Its existing API and institutional data products remain unchanged.
- API2PDF: The service returns a 402 status when an API key is missing, then applies variable pricing that sets the request's expected maximum and charges the actual cost after execution. The company says that previously requiring users to create an account and add a credit card resulted in a drop of more than 50% in conversion after the first month.
What changes in practice?
Monetization Gateway provides a direct path for services designed for automated consumption: an agent can discover a resource's cost, approve it, and execute the request without a human subscription or a pre-existing API key. This opens an additional distribution channel for data and tool providers, but it does not eliminate the need to control pricing, identity, and policies; the current version is geographically restricted and depends on USDC and the Base network, while support for other payment methods and geographies remains part of future plans.
According to Cloudflare, sellers can apply for access through the dashboard and developer documentation. The service remains in a trial phase, so questions regarding scaling, service discovery, agent identity management, and availability outside the United States have not yet been resolved.