Internet Protocol (IPv4) Subnet Chart

Internet Protocol (IPv4) Subnet Chart

Ths is an Internet Protocol (IPv4) Subnet Chart. You can use this to quickly look up how your might need to subnet your network. At the bottom there is a quick how-to on calculating subnets.

For more information on subnetting, see RFC 1817 and RFC 1812.

Class address ranges:

  • Class A = to
  • Class B = to
  • Class C = to


Reserved address ranges for private (non-routed) use (see RFC 1918):

  • ->
  • ->
  • ->


Other reserved addresses:

  • is reserved for loopback and IPC on the local host
  • -> is reserved for multicast addresses


Chart notes:

  • Number of Subnets – “( )” Refers to the number of effective subnets, since the use of subnet numbers of all 0s or all 1s is highly frowned upon and RFC non-compliant.
  • Number of Hosts – Refers to the number of effective hosts, excluding the network and broadcast address.

Class A

Network Bits Subnet Mask Number of Subnets Number of Hosts
/8 0 16777214
/9 2 (0) 8388606
/10 4 (2) 4194302
/11 8 (6) 2097150
/12 16 (14) 1048574
/13 32 (30) 524286
/14 64 (62) 262142
/15 128 (126) 131070
/16 256 (254) 65534
/17 512 (510) 32766
/18 1024 (1022) 16382
/19 2048 (2046) 8190
/20 4096 (4094) 4094
/21 8192 (8190) 2046
/22 16384 (16382) 1022
/23 32768 (32766) 510
/24 65536 (65534) 254
/25 131072 (131070) 126
/26 262144 (262142) 62
/27 524288 (524286) 30
/28 1048576 (1048574) 14
/29 2097152 (2097150) 6
/30 4194304 (4194302) 2


Class B

Network Bits Subnet Mask Number of Subnets Number of Hosts
/16 0 65534
/17 2 (0) 32766
/18 4 (2) 16382
/19 8 (6) 8190
/20 16 (14) 4094
/21 32 (30) 2046
/22 64 (62) 1022
/23 128 (126) 510
/24 256 (254) 254
/25 512 (510) 126
/26 1024 (1022) 62
/27 2048 (2046) 30
/28 4096 (4094) 14
/29 8192 (8190) 6
/30 16384 (16382) 2


Class C

Network Bits Subnet Mask Number of Subnets Number of Hosts
/24 0 254
/25 2 (0) 126
/26 4 (2) 62
/27 8 (6) 30
/28 16 (14) 14
/29 32 (30) 6
/30 64 (62) 2

Supernetting (CIDR) Chart

  • CIDR – Classless Inter-Domain Routing.
  • Note: The Number of Class C networks must be contiguous.
    For example, represents the following block of addresses:,, and

Class C

CIDR Block Supernet Mask Number of Class C Addresses Number of Hosts
/14 1024 262144
/15 512 131072
/16 256 65536
/17 128 32768
/18 64 16384
/19 32 8192
/20 16 4096
/21 8 2048
/22 4 1024
/23 2 512

Quick Subnetting How-To (Thanks to Jason@ GeekVenue.)

[Understanding decimal – Base 10] 

The first thing you must know is that the common number system used world wide is the decimal system (otherwise known as base 10). What makes the decimal system a base 10 system is that it is based on grouping numbers by 10’s. It is believed that the system evolved because we have ten fingers and ten toes which over the years we have used for counting. I use mine all the time (grin). We name the ten digits: zero, one, two, three, four, five, six, seven, eight and nine.

The decimal system has a 1‘s place, a 10‘s place, a 100‘s place, a 1000‘s place and so on. We say the number places are grouped by 10’s because multiplying each number place by 10 gives you the next number place. So: 1×10=10 (the 10’s place), 10×10=100 (the 100’s place), 100×10=1000 (the 1000’s place) etc.

Let’s look at the decimal number 103 by place.

103 <- read from right to left

We have a 3 in the 1’s place
We have a 0in the 10’s place
We have a 1 in the 100’s place

Thus: 100+0+3=103

By now you probably feel like you have attended Kindergarten for the second time in your life? Sorry about that but it is very important that you understand the concept of what a number system is, and what it is based on before we look at binary.

[Understanding binary – base 2]

Binary is a base 2 system, and thus groups numbers by 2’s and not by 10’s like the decimal system. We name the two digits: zero and one. The binary system has a 1‘s place, a 2‘s place, a 4‘s place, an 8‘s place, a 16‘s place and so on. We say the number places are grouped by 2’s because multiplying each number place by 2 gives you the next number place. So: 1×2=2 (the 2’s place), 2×2=4 (the 4’s place), 4×2=8 (the 8’s place), 8×2=16 (the 16’s place) etc.

Let’s look at the decimal number Let’s look at the decimal number 103 in binary format:

01100111 <- read from right to left

We have a 1 in the 1’s place
We have a 1 in the 2’s place
We have a 1 in the 4’s place
We have a 0 in the 8’s place
We have a 0 in the 16’s place
We have a 1 in the 32’s place
We have a 1 in the 64’s place
We have a 0 in the 128’s place

Thus: 0+64+32+0+0+4+2+1=103

Okay, Let’s test your skills. Here is a list of binary numbers, try converting them to decimal and check your answers at the end of this post.


If you were able to convert these numbers to decimal then congratulations! You’re ready to move on to the next section.

[Understanding a subnet mask]

Now that you understand what binary is, let’s have a look at our two subnet masks from the beginning of my post: /

The concept of a subnet mask is simple. You have a network and you have hosts on the network (anything with an IP address is a host). The subnet mask determines what portion of the TCP/IP address represents your network and what portion can be used for your hosts. Because I am a simple person, I think of it like this; The network number represents the street I live on, and the host portion is used for the numbers on all the houses on my street.

A subnet mask of means that the first three octets of the address will be used for the network, and thus our network number is 192.168.1. This means we can have 254 computers on this network, because the fourth octet is not being used by the network portion of the address. We know this because of the in the subnet mask (

We call each of the number sections an octet because we think of them in binary, and there are eight possible bits in each section. Eight bits is an octet. 11111111 in binary is 255 in decimal (did you do the conversions?). So our decimal subnet mask displayed in binary is going to be:


If you count all the ones, you will find that there are 24 of them. Now look at the subnet mask examples again.

Do you see why both subnet masks are the same? The number 24 is the number of bits used in the network portion of the address, and is short-hand for writing the address/subnet mask combination. It becomes important to understand this when you start dividing your network into multiple sub networks.

[Understanding Subnetting]

Before reading this section, you should have a good understanding of what a subnet mask is and how binary bits represent the subnet mask.

Simply put, subnetting is dividing your network into multiple sub networks. To go back to my silly example about houses and streets, subnetting gives you multiple streets in your neighborhood.

There are two methods for dividing your network into multiple sub networks; One is to simply change your network numbers keeping the same subnet mask. The other is to subnet your network into smaller sub networks.

Keeping the same mask:
Your network could be divided into two or more networks by changing the network portion of the address such as 192.168.1 and 192.168.2 and keeping the same subnet mask.


Doing this would give you two separate networks with 254 hosts per network. This is a very common method of dealing with multiple networks. However, back in the good old days you had to pay for every IP address you used, and if you had 25 computers on your network you probably would not want to pay for 254 addresses! The answer to the problem is…subnetting.

Subnetting a network:
Subnetting is when you use bits from the host portion of your address as part of your network number. This let’s you subdivide your network at the cost of host addresses, which is great if you’re paying for every host IP address. It will save you money because you pay for fewer TCP/IP addresses. Confused? Here is where understanding binary is important.

Lets look at a new subnet mask:

As you can see in the fourth octet, some of the host portion of this subnet mask is now being used for part of the network address. Which means we are now using some of the binary bits in the fourth octet for our network numbers, and that gives us fewer hosts than our old mask (which gave us 254), but gives us more networks (which is why we call it subnetting).

How can we tell how many networks and hosts per network this new subnet mask will give us? Well… we shall have to use some of our newly acquired binary skills.

The first task is to find out how many bits in the fourth octet are being used? The decimal number is 224, what is the decimal number 224 as represented in binary?

The decimal number 224 in binary is:

We have a 0 in the 1’s place
We have a 0 in the 2’s place
We have a 0 in the 4’s place
We have a 0 in the 8’s place
We have a 0 in the 16’s place
We have a 1 in the 32’s place
We have a 1 in the 64’s place
We have a 1 in the 128’s place

Thus: 128+64+32+0+0+0+0+0=224

So our complete subnet mask in binary is:

We now know that three bits from the fourth octet are used. How can we tell how many sub networks we’re going to have? This requires some math – sorry. The formula is: 2n-2, where n is thenumber of bits being used from the host portion of our subnet mask.

Important Note:We subtract 2 networks (the first and last subnets) from the total unless we have equipment that supports IP Subnet-Zero in which case we use the formula 2n – please see the addendum at the end of this lesson for more details.

The formula for three bits is:

In simpler terms:

So our network is sub divided into 6 networks. Next, we want to know what the network numbers are, and how many hosts we can have on each of the 6 networks?

What is the first subnet? Let’s have a look at the bits in our fourth octet again. The bit that gives us the answer is the (1) closest to the first zero, and in this case it is the 3rd bit from the left.


The 3rd bit will start our first network, and the 3rd bit is in the 32‘s place (remember binary). Start adding the value 32 to itself six times to get the six network numbers.

Note: A quicker way to find our starting network number is to subtract our mask from 256.

Here are our network numbers:


A better way to display this is:

The host addresses will fall between the network numbers, so we will have 30 hosts per network. You’re probably wondering why it’s not 31? The answer is that the last address of each subnet is used as the broadcast address for that subnet.

Subnet: /
Address Range: through (30 hosts)
Subnet Broadcast Address:

Let’s test your skills- write the address range and broadcast address for the following subnet. You will find the answer at the end of this post.

Subnet: /
Address Range?
Subnet Broadcast Address?

If we we’re paying for our TCP/IP addresses, we would only pay for one network and host combination, thus paying for 30 hosts and not 254. It could mean some real savings, it also frees up the remaining addresses for other organizations to use.

Let’s look at another subnet mask:

How many bits are used from the host portion? To find this out, we need to know how the decimal number 240 is represented in binary.

The answer is:

So four bits are taken from the host portion of our mask. We do the same math as before:


In simpler terms:

We will have 14 sub networks, and what will the network numbers be? Look at the fourth bit, it’s in the 16’s place:

Note: A quicker way to find our starting network number is to subtract the value of our mask from 256. So: 256-240=16

Start adding 16 to itself- fourteen times to get all 14 network numbers:


A better way to display our subnets is:

The host addresses fall between the network numbers. So we will have 14 host addresses on each of our 14 sub networks (remember: the last or 15th address is the broadcast address for that subnet).

If you had a small company with 10 hosts and needed to have a static IP address for all of your hosts, you would be assigned a network/subnet mask and a valid IP address range.

Here is an example of what that might look like:

Address Range: through
Subnet Broadcast Address:

Important Addendum: There may be concerns about why the first and last subnets were not used in any of the examples above. What happened to them? Did they get scared and run away? The answer is simple – nothing happend to them it’s just that some older routing equipment and software does not support the use of the first and last subnets. This is documented in the older TCP/IP doc rfc 950. The newer standard outlined in rfc 1812 allows for the use of the first and last subnets- making it the current standard in IPv4 subnetting.

[Answers to Binary Conversions]

10000000 = 128
11000000 = 192
11100000 = 224
01000000 = 64
10000011 = 131
10010001 = 145
11111111 = 255

[Answer to Subnet Question]

Subnet: /
Address Range: through
Subnet Broadcast Address:



Leave a Reply

Your email address will not be published. Required fields are marked *