Intro to Web Monetization
As a website user, it’s common to encounter a headline that captures your attention, only to find the article locked behind a paywall. How often do you pay for a subscription to read a single article? What if you could pay a fraction of the subscription price to access the article and avoid the subscription altogether?
As a website owner, you anticipate losing a few visitors due to paywalled content. Even if you offer weekly subscriptions, the price may be more than a visitor is willing to pay. But instead of subscriptions, what if you could generate revenue per piece of content, or even based on the amount of time a visitor spends on the content?
These are just two ways in which Web Monetization can make payments easier. With Web Monetization, website visitors can send payments directly to websites using a browser extension or any browser that natively implements the Web Monetization specification.
Current payments infrastructure
It can take a bit of work to implement payments on a website. If your site already accepts payments, you may be familiar with what it takes to accept multiple payment methods and currencies. The process typically looks something like this:
- You sign up with one or more payment providers, depending on the payment methods and currencies you want to accept.
- You integrate their service(s) into your site. For example, you may create and host your own payment form that is connected to the service, or you use a form supplied by the payment provider.
- Depending on the payment method your visitor wants to use, they may need to create an account with you or the payment provider.
- Your visitor fills out the payment form. Ideally, they remain on your site to complete the transaction but may be required to access the provider’s site instead.
Introducing Web Monetization
Web Monetization (WM) aims to simplify the payment experience for you and your website visitors. It’s an open technology that allows websites to automatically receive payments from visitors, facilitated by the visitor’s browser and their preferred WM provider.
It’s a proposed standard that allows your visitors to pay an amount of their choosing with little to no user interaction. It enables a website to automatically signal to web browsers that it can accept payments and enables web browsers to facilitate a payment by:
- Obtaining authorization to initiate the payment.
- Gathering details and issuing instructions to start the money movement process.
- Creating a payment session.
- Communicating payment events to the site so the site can optionally respond. For example, the site could remove ads or provide access to exclusive content for paying visitors.
High-level flow
The following image shows the Web Monetization flow at a high level. Some steps have been combined or excluded. A more in-depth explanation is provided in the Web Monetization flow page.
- Bob visits a web monetized page. The monetization
<link>
element is how the website signals its acceptance of payments to the browser. - Bob’s browser, either natively or via a browser extension, parses the
<link>
element to get the for Alice, the site owner.payment pointer A URL that identifies an Open Payments account - Bob’s browser/extension sends requests to Alice’s payment pointer to obtain authorization and instructions for sending a payment.
- With authorization granted and payment instructions received, the browser/extension sends requests to Bob’s payment pointer to initiate the outgoing payment.
- The Web Monetization flow ends. Payment processing, currency exchange, and settlement occurs between the two accounts via a common payment rail.
Specifying payment amounts and currencies
Web Monetization doesn’t allow a website to specify a payment amount or currency. It only allows the site to tell the browser it can accept payments.
With the help of a
Processing and settling payments
Web Monetization’s role is to help coordinate payments. It does not process or settle payments.
At each end of Web Monetization is an account that supports Open Payments. The WM provider supplies your visitor with a funded sending account. In some cases, the visitor could even act as their own WM provider. The WM receiver supplies you with a receiving account.
Web Monetization communicates with the sending and receiving accounts to obtain the necessary authorizations and instructions for a payment to be sent and received. Payment processing and settlement then occurs between the sending and receiving accounts, outside of the Web Monetization flow.
Prior specification version
A new version of the Web Monetization specification was published in June 2023. Users of the previous version should be aware of the following:
- The previous version only used Interledger’s Simple Payment Setup Protocol (SPSP). The new version uses Open Payments.
- The
<meta>
element is deprecated in favor of the<link>
element. - The
<link>
element does not support the shorthand form of a payment pointer (e.g.,$wallet.example/alice
). You must use the endpoint URL that the payment pointer resolves to (e.g.,https://wallet.example/alice
). If you need help converting a payment pointer from shorthand to its equivalent URL, enter your payment pointer into the input field on paymentpointers.org. In most cases, you can simply replace the$
withhttps://
.