CIDR Notation

Classless Inter-Domain Routing notation, or CIDR notation, is a method of representing an IP address network range.

In CIDR notation, the IP address contains a networking routing prefix and a corresponding prefix length (the number after the /).

For example, IPv4 CIDR 192.168.255.0/24 represents 256 IPv4 addresses from 192.168.255.0 to 192.168.255.255, with a routing prefix of 192.168.255.0 and a prefix length of /24.

For IP addresses using CIDR notation, the prefix length is how many bits have been allocated to the network’s routing prefix.

Firewalls

You can restrict inbound connections to IP addresses or IP ranges. For example, you can enter the CIDR 10.128.0.0/16 into an incoming traffic rule that allows traffic from any IP address between the 10.128.0.0 and 10.128.255.255 to connect to the resource. The same properties apply to IPv6 addresses and CIDRs.

To learn more about configuring rules, see How to Configure Firewall Rules.

For more information about IP addresses, subnets, or CIDR notation.

VPC

We use CIDR notation to represent IP addresses and network ranges in DigitalOcean VPCs.

You can use this table to determine how many usable IPs are available for a specific CIDR prefix on DigitalOcean.

Network Size (CIDR Suffix) Number of Usable IP Addresses
/16 65536
/17 32768
/18 16384
/19 8192
/20 4096
/21 2048
/22 1024
/23 512
/24 256
/28 16

CIDR Notation Articles

See all articles with this tag
Create a load balancer and choose its backend Droplets to improve the availability and flexibility of your infrastructure.