Web Creation Nepal Private Limited
Get a Quote

Contact Support

977-01-5343968 / 9851029233[email protected]
Sunday – Friday: 09:00 AM – 06:00 PM

Payment Gateway Integration in Nepal: Developer Guide

August 12, 2026
8 min read
Share:
Payment Gateway Integration in Nepal
Listen to this article

A comprehensive developer guide on integrating local digital wallets, Esewa, Khalti, ConnectIPS, and international payment gateways like Nabil Bank, Himalayan Bank, and PayPal alternatives in Nepal.

Introduction

To run a successful website or e-commerce platform in Nepal, you need a flexible payment ecosystem. While local buyers rely heavily on digital wallets and mobile banking, global customers or tourism businesses require international card processing.

Proper payment gateway integration in Nepal bridges this gap, allowing your platform to handle both local currency (NPR) and foreign currencies seamlessly.

Local Payment Gateways (Digital Wallets & QR)

For everyday shopping and local transactions, digital wallets dominate the market:

  • eSewa & Khalti: Essential mobile wallets that cover a massive share of everyday online shoppers in Nepal.

  • Fonepay: Perfect for allowing customers to pay instantly by scanning dynamic QR codes directly from their mobile banking apps.

Direct Bank Transfers (ConnectIPS)

ConnectIPS: Handled separately from individual digital wallets, ConnectIPS is a secure, government-backed infrastructure managed by NCHL. It allows direct account-to-account bank transfers, making it ideal for B2B websites, high-value checkouts, and institutional fee payments.

International Payment Gateways

If your website targets global audiences, international clients, or the tourism sector (such as trekking and hotel bookings), you need solutions capable of handling global credit cards:

  • Himalayan Bank (HBL) E-Commerce Gateway: One of the pioneering banking gateways in Nepal that allows local merchants to accept international Visa, MasterCard, American Express, and UnionPay cards.

  • Nabil Bank E-Commerce & International Payment Services: Provides secure merchant integration for handling global card checkouts and foreign currency transactions.

  • A Note on PayPal: Direct merchant account creation and direct gateway integration for PayPal are not officially supported for businesses operating inside Nepal. Local websites targeting international clients typically rely on bank-backed gateways like Himalayan Bank or Nabil Bank to accept global credit cards securely instead.

Comparison Table of All Payment Options

Gateway ProviderTypeCurrenciesBest Suited For
eSewa / KhaltiLocal WalletNPRDaily retail & e-commerce
FonepayQR/Banking NetworkNPRMobile banking users
ConnectIPSDirect Bank ClearingNPRB2B & High-value invoices
Himalayan / Nabil BankInternational AcquirerNPR, USD, etc.Global clients, tourism, hotels, & foreign cards

Step-by-Step Developer Integration Guide

Implementing local wallets (like eSewa or Khalti) or bank APIs follows a concrete technical lifecycle. Below is a detailed breakdown of the development workflow:

Step 1: Merchant Verification & Credential Setup

  • Submit company registration documents, PAN/VAT certificates, and a corporate bank account to the provider (e.g., eSewa, Khalti, or Nabil/Himalayan Bank).

  • Once approved, obtain your Merchant Code/ID and Secret Keys or Auth Keys for testing.

Step 2: Sandbox (UAT) Implementation

  • Always initiate development using the provider's test environments (e.g., eSewa UAT or Khalti Dev endpoints).

  • Use test user credentials and virtual balances to build and verify your checkout frontend forms without processing actual funds.

Step 3: Payload Construction & Signature Generation

  • For Wallets (e.g., eSewa): Construct a POST request payload containing mandatory fields like amount, product_code, and a unique transaction_uuid. Secure the payload using an HMAC-SHA256 signature hashed with your secret key.

  • For Token-Based Checkouts (e.g., Khalti): Send an API POST request to the initiation endpoint with headers containing your authorization key (Authorization: Key <your-secret-key>) and payload details (amount, return_url, purchase_order_id).

Step 4: Handling Callbacks and Server-to-Server Verification (Crucial)

  • When a user completes a payment, they are redirected back to your configured return_url or success_url with parameters like pidx or transaction tokens.

  • Never rely entirely on browser redirects. Always implement a backend server-to-server request (Lookup API or Verification API) to confirm the payment status is marked as Completed directly with the gateway server before saving the order in your database.

Step 5: Production Deployment

  • Replace test API base URLs with production endpoints, swap sandbox keys for live merchant keys, and run a final live transaction test.

For more tutorials on building scalable sites, visit our Web Creation Nepal Blog.

Conclusion

Setting up a robust payment system that handles both local wallets and international cards builds immense trust with your users. If you want a seamless, secure setup without getting bogged down by complicated banking APIs, let our technical experts assist you.

👉 Contact Web Creation Nepal today to get professional help with custom web development and multi-gateway payment integration!

Frequently Asked Questions (FAQ)

Can I integrate PayPal directly into a website based in Nepal?
No, direct merchant account creation and gateway integration for PayPal are not natively supported for businesses operating inside Nepal. Websites targeting global clients use bank-backed gateways like Nabil Bank or Himalayan Bank to accept international credit cards safely.
What essential documents are required to get a merchant account in Nepal?
You generally need your company registration certificate, a PAN/VAT registration document, a tax clearance certificate (or recent renewal proof), and a corporate bank account in the company's legal name.
How long does it usually take to get API credentials approved?
Once all compliance documents are submitted correctly to the wallet provider or bank, merchant verification and sandbox credential issuance typically take anywhere from 2 to 7 business days.
Why is server-to-server transaction verification necessary?
Relying solely on user browser redirects is insecure because users can close the browser or manipulate query strings. A backend lookup verification ensures the payment has genuinely been processed and confirmed by the gateway server.
Are there ready-made plugins available for WordPress or WooCommerce?
Yes! Most major local gateways like eSewa and Khalti provide official or well-maintained third-party plugins for platforms like WordPress and WooCommerce, allowing for quick plug-and-play installation without custom coding.
How do Himalayan Bank and Nabil Bank handle foreign currency?
They provide specialized international e-commerce acquirer accounts that allow verified businesses (like hotels and trekking agencies) to accept global card payments, processing transactions securely via 3D Secure protocols.

Discussion & Feedback

Share your thoughts, ask questions, or provide feedback on this blog. All comments are moderated before being published.

Leave a Reply

Your email address will not be published. Required fields are marked *

Recent Comments

Loading discussion...
Call: 9851029233Email: [email protected]