← Back to Blog
PaymentPromptPayThailandE-commerce

PromptPay QR Payment Integration for Websites: 3 Ways to Do It

5 October 2026 · by Yunmin Shin

Three Ways to Take PromptPay on a Website

You can accept PromptPay on a website in three ways: (1) a static QR with manual slip checks, (2) a dynamic QR from a payment gateway that confirms automatically by webhook, or (3) a QR payment API directly from a Thai bank. Which is right depends on how many payments you take a day and whether a person can check each one.

PromptPay is how Thai customers prefer to pay online — scan, confirm in their banking app, done. Whether you run a shop, take clinic deposits or collect restaurant pre-orders, missing PromptPay costs conversions at exactly the moment the customer is ready to pay.

Option 1: Static PromptPay QR + Slip Check

You generate a PromptPay QR for your business's PromptPay ID (phone number, tax ID or e-wallet ID) with the order amount, show it at checkout, and ask the customer to send the slip.

Generating the QR yourself. A PromptPay QR is a Thai QR Code payload (EMVCo format) that encodes the PromptPay ID and, optionally, the amount. Open-source libraries generate the payload; you render it as a QR image:

import generatePayload from "promptpay-qr"; // npm: promptpay-qr
import QRCode from "qrcode";

const payload = generatePayload("0812345678", { amount: 450.0 });
const dataUrl = await QRCode.toDataURL(payload);
// <img src={dataUrl} alt="PromptPay QR for ฿450" />

Pros: no gateway, no per-transaction fee, set up in a day.

Cons: nothing confirms the payment automatically. Staff must match every slip to the bank statement, and fake or reused slips are a real problem. It works for a handful of orders a day; it does not scale.

Slip-verification services exist that read the QR on a transfer slip and check it with the bank. They reduce fraud but still depend on the customer sending the slip.

Option 2: Dynamic QR Through a Payment Gateway (Recommended Default)

A gateway such as Omise (Opn Payments) or 2C2P creates a one-time QR for each charge. When the customer pays, the gateway calls your webhook and your system marks the order paid — no slip, no human check.

// Server: create a PromptPay charge (Omise example; amount in satang)
const charge = await omise.charges.create({
  amount: 45000, // ฿450.00
  currency: "thb",
  source: { type: "promptpay" },
  metadata: { orderId },
});
const qrImage = charge.source.scannable_code.image.download_uri;
// Webhook: the gateway tells you the charge succeeded
export async function POST(req: Request) {
  const event = await req.json();
  // Verify authenticity per your gateway's docs (signature, or re-fetch the
  // charge by ID with your secret key) before trusting the payload.
  const charge = await omise.charges.retrieve(event.data.id);
  if (charge.status === "successful") {
    await markOrderPaid(charge.metadata.orderId); // must be idempotent
  }
  return new Response("OK");
}

Pros: automatic confirmation, a reference per order, cards and wallets in the same integration, and a dashboard for refunds.

Cons: a per-transaction fee and merchant onboarding (KYC). Compare current fees with each provider — they change and can be negotiable at volume.

Two rules that prevent most payment bugs:

  • The webhook is the source of truth, not the customer's screen. People close the tab right after scanning.
  • Make the handler idempotent. Gateways retry webhooks; a second "successful" event must not double-ship an order or double-book a slot.

Option 3: Bank QR Payment APIs

Major Thai banks offer QR payment and payment-notification APIs to merchants with an agreement. They can be cheaper per transaction at high volume, but onboarding is slower, documentation is often Thai-first, and you usually integrate one bank at a time. They suit businesses already doing high monthly volume, not a new site.

Which Should You Choose?

  • A few orders a day, a staff member watching LINE: static QR + slip check is fine to start.
  • Anything automated — bookings with deposits, online ordering, e-commerce: a gateway with webhooks.
  • High, steady volume and an existing banking relationship: evaluate the bank's own API.

PromptPay Inside LINE

For booking deposits and restaurant pre-orders taken through a LINE LIFF app, the flow is: create the booking as pending, show the dynamic QR in the LIFF screen, and let the webhook confirm the booking and push the LINE confirmation. On a phone, offer a "Save QR" button too — many customers pay by saving the image and opening it in their banking app on the same device.

Before You Go Live

  • Apply for the merchant account early — KYC, not code, usually sets the launch date.
  • Test in sandbox: success, failure, expiry of the QR, duplicate webhooks, and a customer who closes the tab mid-payment.
  • Decide your refund process before your first refund request.

For gateways, cards and the legal side, see payment integration for Thai websites.

Get a free quote. We reply within 24 hours.

Frequently asked questions

What is the easiest way to accept PromptPay on a website?

Show a PromptPay QR for your business account with the amount filled in, and ask the customer to upload or send their transfer slip. It is free and quick to set up, but every payment has to be checked by a person. For automatic confirmation you need a payment gateway or bank API that sends a webhook.

Which payment gateways support PromptPay QR?

Thai gateways such as Omise (Opn Payments) and 2C2P support PromptPay QR along with cards and wallets, and Stripe lists PromptPay for Thailand-based accounts. Major Thai banks also offer QR payment APIs to merchants with an agreement. Check each provider's current fees and onboarding requirements directly.

Can a PromptPay QR include the amount?

Yes. A PromptPay QR follows the Thai QR Code (EMVCo) format and can carry the amount, so the customer's banking app opens with the amount pre-filled. Dynamic QRs from gateways and bank APIs also carry a reference that ties the payment to one order.

How do I know a PromptPay payment has actually arrived?

With a static QR, only by checking your bank account or verifying the slip. With a gateway or bank API, by the webhook the provider sends to your server when the charge succeeds — treat that webhook, not the customer's screen, as the source of truth.

Want this working for your business in Thailand?

We build and run the same systems on 16 live sites of our own. Tell us your business — we reply within 24 hours with what the search data shows.