Navigation

thecodearena.in@gmail.comWorldwide · Remote-first

Commerce3 min read

Setting Up Payment Gateways on a WooCommerce Store in India

How to choose and set up a payment gateway for a WooCommerce store in India — UPI, cards, COD, KYC, webhooks, refunds, GST invoices and testing before launch.

By TheCodeArenaPublished

The checkout is where an online store earns its money, and in India the payment step has its own details: UPI, cash on delivery, KYC, GST and customers who switch between apps mid-payment. This guide walks through the decisions and the setup we follow on WooCommerce stores.

What Indian customers expect at checkout

  • UPI — paying from any UPI app, often by QR code on desktop or an app switch on mobile.
  • Cards and net banking — still important for higher-value orders.
  • Wallets and pay-later options — useful for some audiences.
  • Cash on delivery — many shoppers still want it, especially for first orders.

A gateway that offers UPI, cards and net banking in one checkout covers most customers. COD is handled by WooCommerce itself.

Choosing a gateway

Popular gateways for Indian WooCommerce stores include Razorpay, PayU, Cashfree, CCAvenue and PhonePe’s payment gateway. Rather than recommending one blindly, compare them on:

  1. Activation and KYC — what documents your business type needs (individual, proprietorship, partnership or company) and how long approval takes.
  2. Payment methods — UPI, cards, net banking, wallets, EMI and international cards if you sell abroad.
  3. Pricing — per-transaction charges, any setup or annual fees, and GST on those charges. Check the provider’s current pricing page; it changes.
  4. Settlement time — how quickly money reaches your bank account.
  5. A maintained WooCommerce plugin — recently updated, compatible with your WooCommerce version and with HPOS (high-performance order storage).
  6. Refunds and disputes — whether you can refund from the WooCommerce order screen.

Setting it up properly

1. Use the official plugin

Install the gateway’s official WooCommerce plugin, not a copy from a third-party site. Keep it updated.

2. Start in test mode

Every major gateway has test keys. Place test orders for each method — success, failure and cancellation — before you switch to live keys.

3. Configure webhooks

Webhooks let the gateway tell your store when a payment succeeds, even if the customer closes the browser before returning. Without them you will see “pending payment” orders that were actually paid. Set the webhook URL and secret in the gateway dashboard and confirm that test events arrive.

4. Check order statuses and emails

Paid orders should move to Processing and send the right emails to the customer and to you. Failed payments should not reduce stock permanently.

5. Set up cash on delivery carefully

WooCommerce lets you limit COD, for example by order value or shipping zone. Many stores also confirm COD orders by phone or WhatsApp before dispatch to reduce returns.

6. GST and invoices

Show prices including GST if you sell to consumers, set up tax classes correctly, and add a plugin that generates GST-compliant invoices with your GSTIN. Talk to your accountant about the exact requirements for your business.

Testing before launch

  • Place real low-value orders with each payment method on a phone and a desktop.
  • Switch apps during a UPI payment and come back — does the order still complete?
  • Refund a test order and confirm the money and the order status both update.
  • Check confirmation emails on mobile.
  • Confirm the checkout page loads fast; slow checkouts lose orders.

Common problems we fix

  • Orders stuck on Pending payment — usually missing or failing webhooks.
  • Duplicate orders — a caching or redirect issue on the checkout page.
  • Checkout broken after an update — plugin conflicts, often from an outdated theme.
  • Customers charged but no order — the return URL or webhook is blocked by a security plugin or firewall.

Need a hand?

We set up and fix WooCommerce checkouts as part of our WooCommerce development work, and we built PawBook, a WordPress booking plugin with Razorpay checkout and GST. If your checkout needs attention, get in touch.

Working on something similar? Let's talk.

Tell us what you're building, what you're trying to improve, or simply where you want to go next. We'll help turn the idea into a digital product that works.