Razorpay Payment Extension for Wix
This document covers customer side payment widget only. You'll also need to capture the payments manually
using either Razorpay's Dashboard or webhooks.
Open WIX Editor and add the "HTML Code" element.
Resize and position the element appropriately. Recommended size is 340x520.
Edit and paste following code. Replace
rzp_test_1DP5mmOlF5G5ag shown below with API Keys generated from your Dashboard.
You should see pay button and amount field in preview and published site after saving.
The payment screen appears as shown:
Once the payment is completed, the screen appears as shown:
Additional parameters can be passed using
data- attributes. For example, to customize pay button text, the code is:
You can view list of all possible parameters here.
You can also select a logo and theme color for payment window in Dashboard.
To pass a pre-selected amount, add the
data-amount parameter as well. Note that
data-amount should be specified in paise:
If amount is passed, then user wouldn't be prompted for amount.
To generate API key:
- Log into your Dashboard.
- Select the mode for which you want to generate the API key from the menu ribbon.
- Navigate to Settings.
- Click API Keys.
- Click Generate Key to generate key for the selected mode.
The Key Id and Key secret appear in a pop-out window. You also have the option to download the Key Details.
After generating the keys from the Dashboard, download and save them securely. If you do not remember your API Keys, you need to re-generate it from the Dashboard and replace it wherever required.
You have to generate separate API Keys for the test and live mode. No money is deducted from your account in test mode.
If you have a query, raise a ticket on our Razorpay Support Portal