developer
How to Accept UPI Payments on Your Website Without Paying the 2% Gateway Cut
Step-by-step guide to accepting UPI payments on your website without paying the 2% gateway cut. Learn how direct UPI webhooks eliminate transaction commissions.
Every Indian e-commerce founder, D2C brand, and developer knows the painful reality of monthly payment gateway invoices. Traditional aggregators deduct roughly 2% plus 18% GST (effectively 2.36%) from every single order, extracting tens of thousands of rupees simply for routing a basic UPI transaction.
Here is the exact step-by-step blueprint to accepting UPI payments directly on your website while bypassing the 2% middleman cut.
The 2% Payment Gateway Tax: What You Are Really Paying
Direct Answer: You can accept UPI payments on your website without paying the 2% gateway fee by switching from a custodial aggregator to a direct-to-bank orchestration layer. By generating dynamic, order-specific UPI QR codes and intent links connected to your own merchant account, payments credit directly to your bank while webhook listeners automatically fulfill customer orders.
When an aggregator charges 2% on a ₹5,000 order, you forfeit ₹118 (including GST). Yet the underlying NPCI protocol cost to route that UPI transaction is under 50 paise. Traditional gateways capture that difference as pure middleman rent.
How Direct-to-Bank UPI Orchestration Works
Direct orchestration eliminates the central holding escrow account:
[ Customer at Website Checkout ]
│
▼
[ VyaparGateway API creates Order ] ──► Returns Dynamic QR & Intent Link
│
▼
[ Customer Pays via GPay / PhonePe ] ──► Funds go DIRECTLY to your Bank
│
▼
[ Bank / Merchant Switch Confirms ]
│
▼
[ Signed Webhook hits your Backend ] ──► Auto-fulfill order (Zero 2% cut)
Instead of pooling your money in an aggregator’s nodal wallet for 2 days, funds transfer directly between the customer’s UPI app and your connected business merchant account (e.g. BharatPe, Paytm Business, or HDFC SmartHub).
Step-by-Step Implementation Guide
Step 1: Obtain a Verified Merchant Account
Acquire a free commercial merchant account with a supported provider (BharatPe, Paytm for Business, or HDFC SmartHub). These providers furnish zero-MDR QR collection rails for small and medium businesses.
Step 2: Create a Dynamic Order Session
From your backend server, invoke the order creation endpoint:
curl -X POST https://vyapargateway.com/api/v1/create_order \
-H "X-API-Key: vg_live_YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"client_txn_id": "ORD_94821",
"amount": 2499.00,
"p_info": "Premium Cotton Shirt - Size L",
"customer_mobile": "9876543210",
"redirect_url": "https://yourstore.com/checkout/success",
"callback_url": "https://api.yourstore.com/webhooks/payment"
}'
Step 3: Render the Payment Interface
The API returns:
payment_url: A hosted responsive checkout page.upi_string: A standards-compliantupi://pay?...deep link for mobile intent buttons.qr_image_url: An order-specific dynamic QR code image.
Verifying Payments with HMAC-SHA256 Signed Webhooks
Security is paramount. When payment confirms, VyaparGateway dispatches an HTTP POST webhook to your server with an HMAC-SHA256 signature in the headers.
// Node.js Express webhook verification
import crypto from "crypto";
app.post("/webhooks/payment", express.json(), (req, res) => {
const incomingSignature = req.headers["x-webhook-signature"];
const secret = process.env.VYAPAR_WEBHOOK_SECRET;
const expectedSignature = crypto
.createHmac("sha256", secret)
.update(JSON.stringify(req.body))
.digest("hex");
if (incomingSignature !== expectedSignature) {
return res.status(401).send("Invalid signature");
}
const { status, client_txn_id, amount } = req.body;
if (status === "SUCCESS") {
// Mark order as paid in database & trigger fulfillment
completeOrder(client_txn_id);
}
res.status(200).json({ received: true });
});
Comparing Savings: 2% Aggregator vs Flat-Rate Software
| Monthly Sales Volume | 2% Aggregator Cut (+ GST) | VyaparGateway Subscription | Monthly Cash Saved |
|---|---|---|---|
| ₹2,00,000 | ₹4,720 / month | ₹300 / month | ₹4,420 |
| ₹10,00,000 | ₹23,600 / month | ₹500 / month | ₹23,100 |
| ₹50,00,000 | ₹1,18,000 / month | ₹700 / month | ₹1,17,300 |
| ₹1,00,00,000 | ₹2,36,000 / month | ₹700 / month | ₹2,35,300 |
Take control of your payment margins today with VyaparGateway’s Developer API.
Direct answers
Frequently asked questions
- How can a website accept UPI payments without paying a 2% gateway fee?
- Websites can eliminate 2% gateway fees by connecting an authorized direct merchant account (such as BharatPe, Paytm Business, or HDFC) via direct-to-bank orchestration software like VyaparGateway, which generates dynamic order QRs and verifies payments via signed webhooks for a flat SaaS subscription.
- Is bypassing traditional payment gateway commissions legal in India?
- Yes. Connecting your own bank-approved merchant UPI account to automate order-linked reconciliation on your own website is 100% legal, compliant with RBI guidelines, and standard practice for high-volume merchants.
- Do customers notice any difference during checkout?
- No. Customers experience the exact same seamless checkout: scanning a dynamic UPI QR code on desktop or tapping an intent button (Google Pay, PhonePe, Paytm, BHIM) on mobile with instant payment confirmation.
Build your payment flow
Explore the API and browser-only merchant tools.
Create UPI checkout orders, verify signed events, or test the free calculators and generators without exposing credentials.