Add Alipay to Your Website for Customers in China
Add Alipay for customers in China without business paperwork. Individuals can start with EPay right after signing up and have payment channels ready in as little as one hour.
An Alipay button is only the start of a website integration. The more useful question is what happens after someone clicks it: which order are they paying for, and how will your website know when to deliver the purchase?
With EPay, an individual seller can add Alipay for customers in China without submitting business paperwork. Sign up to start using EPay; Alipay and WeChat Pay channels can be ready in as little as one hour.
If you already have a website, begin with its existing order flow. Adding a payment method does not have to mean rebuilding your product pages or customer accounts.
Start with the order your website owns
Before opening payment, your server should have a business order it can look up. That order identifies the customer, the purchase, the amount due and whether payment is still allowed.
For example, your website might assign WEB-1048 to a template purchase. The payment service may return its own reference when you create the payment. Store the relationship between those identifiers so a notification or support request leads back to the right purchase. The reference here is an illustration, not an API field specification.
Calculate the amount on your server using your product and pricing rules. Don’t simply trust a number sent by the browser. Apply the amount units and formatting required by the integration documentation, and make sure the displayed price, payment request and stored order agree.
The return page shows progress to the customer. The verified order state on your server determines whether fulfillment happens.
Give the customer the right next step
A customer on a desktop may use a phone to finish paying. A customer already on a phone needs a practical way to continue on that device. The exact flow depends on the payment option enabled for your account, so avoid using one set of instructions everywhere.
Keep the product, amount and Alipay option easy to recognize. If payment takes the customer away from your page, explain that briefly. When they return, reopen the existing order rather than treating every page load as a new purchase.
If a payment link or QR code expires, explain what happened. Before offering a new way to pay, your server should check that the original order is still payable. Attempts through the old and new checkout must not cause duplicate fulfillment.
Separate the browser return from payment confirmation
There are two events to think about: the customer returns to your website, and your server receives a payment result. The first tells you where the browser is. It does not by itself prove that the order was paid.
Process server notifications according to the integration documentation. Verify their source and signature, match the order and amount, and check the payment status before delivering anything. A repeated successful notification should receive the appropriate response without triggering fulfillment twice.
If a notification hasn’t arrived, use the documented status-query process rather than relying on the customer to refresh the page. Our guide to paid orders still showing as unpaid covers that investigation in more detail.
Test more than the happy path
Use one test order to inspect the whole journey:
| Point in the journey | What to check |
|---|---|
| Product page to order page | Product, quantity and amount remain consistent |
| Customer selects Alipay | The payment belongs to the existing order |
| Customer finishes paying | Your server obtains and verifies the result |
| Customer closes the payment window | The backend can still confirm the order |
| Customer opens the order again | The existing result appears without another delivery |
The closed-window case is easy to overlook. A real customer may pay and move on without returning. Your system still needs to complete that purchase. The reverse matters too: returning after canceling payment should not activate a product or release a download.
Leave a trail that support can follow
For an order investigation, keep your order ID, the provider reference, amount, time and current status available. Logs can help explain a failure, but should not contain full secrets or unnecessary personal payment details.
Read the Alipay channel overview and create an EPay merchant account to arrange the setup for your website. Use the integration guide for preparation and the launch checklist before opening checkout. A useful integration is one where you can follow the purchase all the way through, including when the customer doesn’t take the expected route back.