How to Accept UPI Payments on Your Website Without a Payment Gateway
A dynamic QR, app buttons and a simple verification step can replace a gateway for small sellers. Here is how it works, and where it breaks.
In this article
- How a UPI payment link actually works
- Add app buttons for mobile users
- The part people skip: confirming the payment
- 1. Manual approval
- 2. Automatic screenshot check
- 3. Merchant UPI with payment notifications
- What the customer flow should look like
- Is it allowed to take business payments on a personal UPI ID?
- Quick checklist before you go live
Payment gateways are great until they aren't. A new account can take days to approve, some categories get rejected outright, and settlements can be put on hold right when you need the money. That's why a lot of small sellers in India simply share their UPI ID on WhatsApp and wait for a screenshot.
You can do the same thing on your website, just in a cleaner way. The customer sees a QR code with the exact amount already filled in, pays from any UPI app, and uploads proof. Your site checks the details and unlocks the order. No gateway fee, no waiting for approval.
This guide explains how that flow works, what you need to build it, and the honest limitations you should know before you depend on it.
How a UPI payment link actually works
Every UPI QR code is just a text link that starts with upi://pay. When a UPI app reads it, it fills in the details for the customer. A typical link looks like this:
upi://pay?pa=yourname@okhdfcbank&pn=Your%20Store&am=499.00&cu=INR&tn=Order%20OD123
The parts that matter:
- pa is your UPI ID (payee address).
- pn is the name shown to the customer.
- am is the amount. Put it here and the customer doesn't have to type it.
- tn is a short note. Putting the order number here makes matching payments much easier later.
Because the amount is part of the link, you generate a fresh QR for every order. On a PHP site that's one line to build the link and a small JavaScript library to draw the QR in the browser.
Add app buttons for mobile users
Scanning a QR on the same phone you're paying from is awkward. On mobile, it's better to show buttons that open the payment app directly. The same link works with different prefixes:
| App | Link starts with |
|---|---|
| Any UPI app | upi://pay? |
| PhonePe | phonepe://pay? |
| Google Pay | tez://upi/pay? |
| Paytm | paytmmp://pay? |
One thing to test yourself: some apps are strict about payments to personal UPI IDs opened from a link and may show a warning or a limit. The QR scan route almost always works, so keep both options on the page.
The part people skip: confirming the payment
Without a gateway, nobody tells your server "this order is paid". You have to confirm it. There are three common ways, from simple to more automatic.
1. Manual approval
The customer uploads a screenshot and the transaction reference (UTR). You open your bank app, find the UTR, check the amount and click Approve in your admin panel. It's slow, but it's the most reliable method, and for 10–20 orders a day it's perfectly fine.
2. Automatic screenshot check
An OCR service reads the text in the screenshot. Your code then checks three things: the UTR the customer typed appears in the image, the exact order amount appears, and your account name appears as the receiver. If all three match and the screenshot doesn't say "pending" or "failed", the order unlocks on its own.
Two rules make this much safer:
- Never reuse a UTR. Store every UTR with a unique index in the database so the same payment can't unlock two orders.
- Never reuse a screenshot. Save a hash of each uploaded file and reject duplicates.
3. Merchant UPI with payment notifications
If you open a business/merchant UPI account, many banks and PSPs offer payment alerts or APIs. That's the most automatic option, but it brings back some of the paperwork you were trying to avoid.
What the customer flow should look like
- Customer fills in name, mobile number and password at checkout.
- The site creates the order and shows a QR with the amount.
- Customer pays and comes back to the same page.
- They upload the success screenshot and type the UTR. They should not have to type the amount; your system already knows it.
- The order is either approved instantly or marked "being confirmed", with a WhatsApp button in case they need help.
Logging the customer in at step 1 matters more than it seems. When the payment is approved, the course or product is already sitting in their dashboard. They don't have to remember a password they created two minutes ago.
Be honest with yourself about fraud. A screenshot can be edited. Automatic checks catch lazy fakes and reused proofs, but a determined person can still fool OCR. For high-value orders, keep manual confirmation on until you trust the pattern.
Is it allowed to take business payments on a personal UPI ID?
Lots of small sellers do it, but banks expect personal accounts to be used personally. If your volume grows, a current account and a merchant UPI ID are the safer route, and your customers will see a business name instead of a person's name. Treat the personal-UPI setup as a starting point, not a permanent system.
Quick checklist before you go live
- QR shows the exact amount and the order number in the note.
- Your bank account name is saved in settings so the screenshot check can match it.
- UTR and screenshot hash are unique in the database.
- Uploaded screenshots are stored in a folder that is not publicly accessible.
- Admin can see the screenshot, approve, reject with a reason and release a UTR if needed.
- Refund and terms pages clearly mention how UPI payments are verified.
Set up well, this flow handles the first few hundred orders of a small business comfortably. When it starts taking too much of your time, that's a good problem: it means you're ready for a proper gateway.
Frequently asked questions
Do I need a payment gateway to sell on my website?
Can someone fake a payment screenshot?
Should the customer enter the amount?
Was this guide helpful?