Skip to main content
Whitelisting your IP address provides a layer of authentication. This prevents unauthorised API requests and ensures only verified requests are processed.
IP whitelisting is required for both the sandbox (test) and production environments. You configure it as a two-factor authentication (2FA) method in the Merchant Dashboard.

Prerequisites

Before you whitelist an IP address, ensure the following:
  • You have generated your API credentials.
  • You have a public IPv4 address. Cashfree does not support IPv6 or private IP addresses, including the 10.x.x.x, 172.16.x.x to 172.31.x.x, and 192.168.x.x ranges, because these are not accessible over the public internet.
  • You plan to whitelist no more than 10 IP addresses.

Whitelist an IP address

To whitelist your IP address, follow these steps:
  1. Log in to the Merchant Dashboard.
  2. Go to Developers > Two-Factor Authentication under the Secure ID card.
  3. Select IP Whitelist from the Select 2FA Method drop-down.
  4. Select Add IP Address.
  5. Enter the IP address you want to whitelist and select Add IP Address to save.
The whitelisted IP addresses are displayed in the grid. Grid showing whitelisted IP addresses in the Cashfree Secure ID dashboard

Find your IP address

Use your public IPv4 address, not a private or local network address. You can find your public IP address using either of the following methods.

Use a browser

Open a browser and visit a service such as whatismyipaddress.com.

Use the command line

From the server that will call the API, run the following command:
The command returns your public IPv4 address.