Payment Request API
More info
- Owner
- W3C (Web Payments Working Group)
- Released
- 2016–
- Type
- Web standard
- Spec
- w3.org/TR/payment-request
A browser API that lets a site request a payment and hand the checkout form itself to the browser or a payment app.
The pitch was that nobody should have to type a card number into yet another form. The site builds a PaymentRequest object with an amount and the accepted payment methods, calls show(), and gets a response back from a dialog drawn by the browser. Chrome shipped it first in 2016, and the W3C published it as a Recommendation in 2022.
The original plan didn't survive contact with reality. The basic-card method, in which the browser handed over saved card numbers itself, was removed around 2022, since it mostly moved the PCI problem into the browser. What remained is a common entry point to wallets such as Apple Pay and Google Pay. Most merchants therefore use it without knowing, buried inside their payment gateway's button.