Classless Inter Domain Routing For Beginners

What Is CIDR?

Learn all about CIDR and how essential it is for today's Internet.

The Internet is constantly changing and evolving, and with it, the way we allocate IP addresses. Classless Inter Domain Routing (CIDR) is a more efficient way of allocating addresses than the traditional classful network addressing system. CIDR was created by the Internet Engineering Task Force in 1993 to impede the growth of routing tables and slow down the depletion of IPv4 addresses.

The main goal of this article is to answer some important questions: What is CIDR? How does it work? What are the main features and advantages? If you’re interested in learning more about Classless Inter-Domain Routing, continue reading.

How does CIDR really work?

The basis of CIDR is variable-length subnet masking (VLSM). This numerical masking sequence allows network administrators to break down an IP address space into subnets of various sizes. Each subnet has a different host count and a limited number of IP addresses.

CIDR, or Classless Inter Domain Routing, is a numerical masking sequence that allows network administrators to break down an IP address space into subnets of various sizes. Each subnet has a different host count and limited number of IP addresses. A CIDR IP address may look something like this: which contains two groups of numbers: the Network Prefix (123.45.67) and the Suffix (/12). Routers that operate on CIDR rely on the destination address to route packets towards the gateway, then based on the details of the supernet or supernetwork further unpacking ensues until either the most specific network address or largest one is reached.

What are CIDR blocks?

CIDR blocks are groups of IP addresses that share the same network prefix and number of bits. They can be combined into a larger routing network called supernetting, which is essential for today's Internet. IP addresses with an identical address prefix in their binary notation and the same number of bits always belong to the same CIDR block.

The Internet Assigned Numbers Authority (IANA) takes care of the assignment of the larger blocks to Regional Internet Registries (RIRs) to Local Internet Registries (LIRs), who then divide them into individual addresses dedicated to end-users. The internet service provider (ISP) assigns blocks to an end-user for their private network, but organizations and individuals using multiple ISPs may obtain provider-independent blocks directly from RIRs or LIRS.

What is CIDR notation?

To put it simply, a network identifier is the network portion of an IP address. A host identifier indicates the numbers that remain available after subnetting an IP address.

For example, Class A uses the first 8 bits for the network identifier, whereas Class B and Class C use 16 and 24 bits, respectively.

A network mask, also known as a netmask, defines the class and range of an IP address.

When discussing the division of a network into further subnets, we refer to subnet masks that come from such division, which only contributes more bits to the network mask.

An IPv4 address is a 32-bit number that can be split into four octets, each of which can be represented in decimal or binary form. The first eight bits (the network identifier) identify the gateway router for a particular network, while the remaining 24 bits (the host identifiers) are available for all systems on that network. A subnet mask defines the class and range of an IP address. When discussing subnets, we refer to masks that come from such divisions, which contribute more bits to the overall netmask.

Why use CIDR?

In a nutshell, CIDR is essential for managing the complexity of modern networking. It dramatically reduces the number of routing table entries required, making network management much more efficient. But that's just one advantage - there are many others!

Issues present with class-based IP addressing

The original class-based IP addressing depleted the stock of available IP addresses at an alarming rate.

There are three classes within the class-based addressing system:

  • Class A – maximum of 16,777,214 hosts

  • Class B – maximum of 65,534 hosts

  • Class C – maximum of 254 hosts

Class-based IP addressing is no longer efficient due to the depletion of available IP addresses. This system has three classes, each with their own limitations. An organization that needs more than 254 host identifiers must switch to class B, even if they don't need all 65,534 hosts. This wastes 60,000 unused IP addresses.

Advantages of using CIDR

CIDR is a system that allows for the organization of IP addresses into multiple subnets, regardless of their value. This makes routing traffic much quicker and easier, as well as reduces wasted address space. Additionally, CIDR allows for the aggregation of subnets into a supernet for more efficient network routing.

CIDR and subnets

Once ISPs deliver blocks of IP addresses to individual users and their home networks, CIDR further divides them into subnets within an internal network.

All specific computers and individual devices in the same subnet have the same IP address prefix. The subnet ID of the host ID can distinguish between those devices in a subnet.

CIDR is a system that helps to divide IP addresses into smaller, more manageable chunks. This is essential for the modern internet, as it allows ISPs to deliver blocks of addresses to users and their home networks. Within these subnets, all devices will have the same prefix address, making it easier to identify them. The subnet mask determines how many subnets are available in a network - 255 being the highest value possible.


The Classless Inter Domain Routing addressing scheme is a key technology that helps manage internet protocol addresses and control the depletion of IPv4 addresses. With CIDR, a single entry in a routing table can be used for a group of networks, which reduces the number of entries in a router and results in smoother and quicker operation. While measures have been implemented to slow down global IPv4 exhaustion, the fight against it continues.