In this tutorial, we learn to create or whitelist an IP address in Salesforce Lightning and Salesforce Classic.
Salesforce IP Addresses
An IP address is a string of a set of 4 numbers that are separated by periods, for example, 66.231.80.0 is an IP address. These numbers in the set of IP addresses can range from 0.0.0.0 to 255.255.255.255. In Salesforce we used a list of specified IP addresses to avoid unauthorized access to the organization’s data in Salesforce. With the help of these IP addresses users can always log in without receiving a login challenge.
Salesforce Support occasionally requests a subset range of IPs to allow. It is advised that we should allow the entire list of Salesforce IP ranges for seamless access. Narrowing the range of IP addresses would put you at risk of interrupted access for you and the users.
The Network Engineering team of Salesforce recommends allowing the following IP ranges:
Region | Connections to Salesforce | Connections from Salesforce |
USA | 3.228.190.251 34.206.116.149 35.174.143.92 52.203.77.201 54.156.107.163 54.158.77.4 54.163.166.54 54.83.60.38 107.21.202.122 | 3.225.151.145 3.225.240.254/32 18.204.28.162/32 18.211.105.61 34.197.58.108 34.204.111.166/32 52.3.16.30 52.22.251.194 52.70.135.185 |
Whitelist IP address in Salesforce Lightning
To Whitelist IP addressed in Salesforce Lightning, login to your Salesforce account and follow the steps below.
Step 1- To go to the Setup page of Salesforce Lightning, click on the gear icon on the upper right side of the screen, then in the dropdown select the option Setup.

Step 2- On the Setup page of Salesforce Lighting, click on the Quick Find box and search for network access, and under the heading Security, select Network Access.

Step 3- In the Network Access Setup you can create a list of trusted IP address ranges from the sources that your organization trusts. With these IP addresses Users can log in to the salesforce.com with a browser from a trusted network. Now to create or set up a new IP address click on the New button.

Step 4- In this step, we will enter the range of valid IP addresses from which the user logins are trusted, and for that, we will fill in details in the required fields. First in the Start IP address field enter a valid IP address with a low-value number of four sets, like I have entered 204.0.0.0 as the Start IP address.
Now enter a higher value number of four sets in the End IP Address field. I have entered the 204.14.239.255 in the End IP address field which is a higher value of 204.0.0.0 after this enter the description regarding the IP Address in the Description field and then click on the Save button.
The start and end IP address in an IPv4 range must include no more than 33,554,432 addresses. For example, the following ranges are valid:
- 0.0.0.0 to 1.255.255.255
- 132.0.0.0 to 132.255.255.255
And if you want to allow users to login from a single IP address then you can enter the same range in Start and End IP address fields.

As we click on the Save button the new IP address will be created and it will be added to the list of Trusted IP ranges as shown in the picture below.

Now we have successfully whitelisted a new IP address in Salesforce Lightning.
Read How to install and use Salesforce Inspector
Whitelist IP address in Salesforce Classic
Login to your Salesforce account to, whitelist an IP address in Salesforce Classic.
Step 1- On the home page of Salesforce Classic click on the Setup tab, which will redirect us to the Setup page of Salesforce Classic.

Step 2- On the Setup page of Salesforce Classic, click on the Quick Find box and search for Network access there and from the dropdown select Network Access under the heading Security Controls.

Step 3- In the Network Access setup click on the New button to create a new IP address.

Step 4- Now in the Trusted IP Range Edit window, enter the required details to specify the IP address range. The start and end IP address range must include no more than 33,554,432 addresses. For example, the following ranges are valid:
- 0.0.0.0 to 1.255.255.255
- 132.0.0.0 to 132.255.255.255
In the Start IP Address field enter the IP address range with the value of four sets. I have specified the Start IP Address as 52.203.77.201 and in the End IP Address field, we can enter a value higher or equal to the Start IP address. So I have entered the End IP Address as 52.203.77.201 which is equal to the Start IP address. After specifying the IP addresses write the description in the Description field for the specified IP range and last click on the Save button.

As we click on the Save button, a new IP address will be created and it will be visible in the list of Trusted IP Ranges as shown in the picture below.

With the above step, we have successfully whitelisted an IP address in Salesforce Classic.
Conclusion
In this tutorial, we have learned about Whitelisting an IP address in Salesforce Lightning and Salesforce Classic respectively. We also learned about the uses of IP addresses and when it is required to access an IP address. Along with this, we came to know about the valid range of IP addresses which should be used while whitelisting an IP address.
You may like to read:
I am Bijay Kumar, the founder of SalesforceFAQs.com. Having over 10 years of experience working in salesforce technologies for clients across the world (Canada, Australia, United States, United Kingdom, New Zealand, etc.). I am a certified salesforce administrator and expert with experience in developing salesforce applications and projects. My goal is to make it easy for people to learn and use salesforce technologies by providing simple and easy-to-understand solutions. Check out the complete profile on About us.