How can I add a list of IP ranges to be whitelisted in Azure Cosmos DB?

Sheethal Pai 0 Reputation points

From Azure Cosmos DB networking tab, I'm able to add individual IP address for whitelisting But I have a few IP ranges. Please let me know how to add them.

Azure Cosmos DB
Azure Cosmos DB
An Azure NoSQL database service for app development.
1,526 questions
{count} votes

2 answers

Sort by: Most helpful
  1. TP 83,066 Reputation points

    Hi Sheethal,

    You can add the public IP ranges in Classless Inter-Domain Routing (CIDR) format. You can use a free online IP range to CIDR calculator to help (search engine will give many to choose from).

    For example, say you wanted to allow IP range -, you would enter on the Networking blade of your Cosmos DB.

    Please click Accept Answer and upvote if the above was useful. If something is unclear or you need additional assistance for a specific range, add a comment below.



    1 person found this answer helpful.

  2. Sajeetharan 2,031 Reputation points Microsoft Employee

    Check the way to add using the Azure CLI here

    # Create an Azure Cosmos DB account with default values and IP Firewall enabled




    # Make sure there are no spaces in the comma-delimited list of IP addresses or CIDR ranges.

    az cosmosdb create -n $accountName -g $resourceGroupName --locations regionName='West US 2' failoverPriority=0 isZoneRedundant=False --locations regionName='East US 2' failoverPriority=1 isZoneRedundant=False --ip-range-filter $ipRangeFilter

    0 comments No comments