Store customer's card details securely as tokens to repeat transactions made by the customer.
You can save customer card details in the form of tokens with Razorpay. The next time the customer makes any transactions, the customer can pay directly by entering the CVV of the card. This saves the customer the hassle of entering the card details multiple times for each transaction. As per the RBI guidelines, Razorpay will not save sensitive card details; we only save the tokens.
Watch Out!
For a safer and secure payment experience, please advise your customers to log out of the Saved Cards feature after completing the payment. Doing so avoids any misuse of the card information.
Test Mode API Keys
Watch this video to know how to generate Test Mode API keys.
Live Mode API Keys
Watch this video to know how to generate Live Mode API keys.
Flash Checkout enables you to save customer card details on Standard Checkout. Authentication is done using PCI-DSS compliant technology to ensure that all the card information is stored securely.
Create a customer whose card details should be saved from the Dashboard or using the Customers API. You can create customers with basic details such as email and contact using the following endpoint:
The following endpoint creates or add a customer with basic details such as name and contact details. You can use this API for various Razorpay Solution offerings.
string Customer's name. Alphanumeric value with period (.), apostrophe (') and parentheses are allowed. The name must be between 3-50 characters in length. For example, Gaurav Kumar.
contact optional
string The customer's phone number. A maximum length of 15 characters including country code. For example, +919876543210.
email optional
string The customer's email address. A maximum length of 64 characters. For example, gaurav.kumar@example.com.
fail_existingoptional
string Possible values:
0: If a customer with the same details already exists, fetches details of the existing customer.
1 (default): If a customer with the same details already exists, throws an error.
gstinoptional
string Customer's GST number, if available. For example, 29XAbbA4369J1PA.
notesoptional
object This is a key-value pair that can be used to store additional information about the entity. It can hold a maximum of 15 key-value pairs, 256 characters (maximum) each. For example, "note_key": "Beam me up Scottyβ.
While making the payment, the customer enters the card details in the Checkout form. Pass customer_id and save=1 along with the other parameters into the Checkout form.
Once the card is saved, customers can complete payments on repeat purchases by only entering the CVV. To fetch saved cards, pass the customer_id to the Checkout form.
For a safer and secured payment experience, your customer must log out from the Razorpay Checkout by following these steps:
Open Razorpay Checkout.
Select Card as the payment method.
Click the drop-down and select Log out from all devices.
This logs the customers out from the saved card feature on Checkout.
Watch Out!
For a safer and secure payment experience, please advise your customers to log out of the Saved Cards feature after completing the payment. Doing so avoids any misuse of the card information.