Skip to main content
  1. Show Google Pay as a separate option.
  2. Trigger payment when the user clicks Google Pay at your checkout.
Google Pay, previously Google Tez, can be integrated using two types of UPI flows:
  • Collect Request Flow: This flow is available on desktop and mobile browsers. The customers enter their Google Pay VPA on the checkout form. Upon triggering a payment request via Razorpay’s upi method, the Collect request reaches the customer’s Google Pay application. The customer then completes the payment.
  • Intent-based Payment: This flow is applicable only to mobile and mobile-web payments. In these cases, the customer is redirected to Google Pay’s application to complete the payment. Intent-based payments are available on the Android SDK and on Google Chrome for Android (v56 and above, but not on Google Chrome WebViews).

Prerequisites

  1. Sign up for a business account with Google Pay.
  2. Contact our Support Team and have them whitelist your VPA (UPI ID).
  3. Verify your VPA (UPI ID) details on the Google Merchant Console. Google deposits a small amount into the bank account linked to your VPA (UPI ID).
  4. You should have already integrated one of the following:
  5. Generate API Keys from the Dashboard.

General Branding Guidelines

Refer to Google’s Branding Guidelines to learn about the general branding guidelines for Google Pay on the front-end of your websites and apps.

Desktop Integration

On desktop browsers, the Collect request flow works the same way as Razorpay’s UPI.
  1. Collect the customer’s VPA and pass it in the payment request with method as upi.
  2. Razorpay then triggers a Collect request. The collection request is sent to the customer’s Google Pay application where they can make the payment.

Mobile-Web Integration (Google Chrome)

Handy TipsAs the APIs exposed by Google Pay are available only in Chrome’s JavaScript engine, you will need to use our JavaScript-based integration.
Watch Out!This feature is only available for webpages running on HTTPS.On mobile-web, for intent-based payments, the flow should be as follows:
  1. Check if Google Pay is installed on the user’s device. If installed, show the necessary UI elements.
  2. Once the user chooses to pay using Google Pay, you can initiate an intent-based payment from your checkout.
  3. Google Chrome will request the user to make a payment using Google Pay.

Detect Google Pay Installation on Device

  1. Add Razorpay.js to your website
    Know more about Custom Web Integration.
  2. Instantiate Razorpay
  3. Detect if Google Pay on available on the device

Initiate Payment Using Google Pay

  1. Create a payment through Google Pay. Skip passing the vpa field in the payment data and pass { gpay: true } as the second argument to createPayment.
Refer to the Success/Error Callbacks section for more details.

Android Integration

UPI Collect Flow DeprecatedAccording to NPCI guidelines, the UPI Collect flow is being deprecated effective 28 February 2026. Customers can no longer make payments or register UPI mandates by manually entering VPA/UPI id/mobile numbers.Exemptions: UPI Collect will continue to be supported for:
  • MCC 6012 & 6211 (IPO and secondary market transactions).
  • iOS mobile app and mobile web transactions.
  • UPI Mandates (execute/modify/revoke operations only)
  • eRupi vouchers.
  • PACB businesses (cross-border/international payments).
Action Required:
  • If you are a new Razorpay user, use UPI Intent.
  • If you are an existing Razorpay user not covered by exemptions, you must migrate to UPI Intent or UPI QR code to continue accepting UPI payments. For detailed migration steps, refer to the migration documentation.

Intent-Based Integration

On Android, for intent-based payments, first you need to check if Google Pay is installed on the user’s device. You can use the razorpay.getAppsWhichSupportUpi method to retrieve the list of apps that support intent-based payments installed on a phone. When a user selects Google Pay as the payment method, you need to submit the Google Pay’s package name along with other checkout options to the Razorpay function razorpay.submit:
Additionally, if you want to open Google Pay within your application for customers to make the payment without any redirection, you can do so by integrating with Google Pay SDK.

Intent-Based Integration Using Google Pay SDK

You also have the option to integrate Google Pay with the Custom Checkout on your Android app using Google’s SDK. This offers the advantage of letting you open Google Pay within your application for customers to make the payment without any redirection, improving the user experience.

Collect-Based Integration

This is the same as the existing UPI Collect Integration.
  1. Collect the customer’s VPA and pass it in the payment request, with method as upi.
  2. Razorpay then triggers a collect request. The collection request is sent to the customer’s Google Pay application, where they can make the payment.
NPCI Restrictions for UPI Collect Flow As per NPCI guidelines, the following MCC codes are restricted and cannot accept UPI Collect payments:

Restricted MCC Codes

MCC Code | Category

5816 | Digital Goods: Games

6540 | POI Funding Transactions (excluding MoneySend)

4812 | Telecommunication Equipment and Telephone Sales

4814 | Telecommunication Services

7408 | Lending Platform

6513 | Real Estate Agents and Managers - Rentals

7995 | Betting/Lottery

5412 | Grocery Stores, Supermarkets

5413 | Grocery Stores, Supermarkets To integrate Google Pay with the Checkout on your Android app using Google’s SDK:
  1. Download the Google Pay SDK and add the .aar files to the application library.
Handy TipsThe Razorpay-Google Pay SDK acts as a wrapper over the native Google-SDK. This SDK connects Razorpay’s SDK with the Google SDK. You need all the 3 SDKs (listed below) for the flow to work.
  • Razorpay Android SDK
  • Google Pay SDK
  • Razorpay-Google Pay SDK
  1. Add the following lines of code to the build.gradle file of your application:
    build.gradle
This adds the dependencies for the SDK and creates a Google Pay UPI payment method on your Checkout form.