Subnetting in Decimal (Fast Way)

This is DOPE! Rene is a real beast!

1 Like

Hi Rene,

I see that you have mentioned that is the first subnet and is the second subnet. I am confused as to why we didn’t we use as first subnet. Why is the ZERO subnet missing?? Please help.

Hello Ajeet

When doing subnetting, the first thing you define is the full range of addresses that you begin with. This is typically what the ISP will give you or what you have to work with within your network. From this range of addresses, you begin subnetting into smaller subnets.

In Rene’s example, the original network range that you are given is the subnet with a mask of This is provided by definition. You are then asked to subnet this range. In the lesson, the you are initially asked to use a subnet mask of So by definition again, the very first subnet will be because that is what you have been given and the second will be

Now if you were given the initial range of and asked for example to use a subnet mask of, then the first subnet would be, again because that’s what you are given to start with. The next would be, then etc…

I hope this has been helpful!


Thank you for replying Lazaros.

In your second paragraph, you have mentioned that if we were to subnet to subnet mask /25, then the first subnet should be Why can’t we take the first subnet as - This can be the network address and the broadcast address can be
Also, I think in the first line of 3rd paragraph, it should be Please correct me if I am wrong.
Adding to it, I would also like to know if VLSM is enabled on all the routers by default or we have to enable it. Because, I guess the router will assume fixed size subnets if we don’t enable VLSM.


Hello Ajeet

If you are originally given a range of, and you begin dividing it into smaller subnets, the first subnet is always the lowest. So if we begin dividing this into /28 subnets for example, the first subnet will be The second will be, then and so on. Of course, each subnet has its network address, first, last and broadcast addresses as well…

Actually, I meant /23. gives us a range of addresses from to
If we subdivide this into smaller subnets using the, then we get the following subnets:

The example I used was to show that you start with an original range, and depending on the sizes of the subnets you want to make, you can divide that into smaller pieces.

I hope this has been helpful!


I think there is a small mistake in the class A part. Broadcast address of subnet 3 should be instead of (a bit further up it is indeed typed as ‘’).


Very good lesson btw! I did Cisco courses at a uni and up to today did not understand how to calculate the IP address range with large subnetworks, but now I really do understand. Thank you!

1 Like

Hello Marit

Thanks for pointing this out as well. Will let @ReneMolenaar know.


Thanks Marit, fixed this!

I just want to no if i do well for the exercise it’s possible to have
Subnet16 on classC

Hello Raoul

Yes, it is possible to have a /16 subnet on a network like (I’m assuming the 262144 you wrote was a typo). Actually, you can have any subnet size on any range of IP addresses if you are working in a classless environment. So simply means that you have the following: is the network address is the first host address is the last host address is the broadcast address.

Using Cisco equipment, you have no problem in configuring something like this. However, some other vendors, especially commercial grade routers, access points, switches, IP cameras, and other devices may have a restriction on the size of the subnet. Many of these devices have a classless networking behaviour hardwired into their circuitry. In such cases you will have to conform to whatever limitations you have.

I hope this has been helpful!


Oh yeah!! This method is rocking Andrew!! Much obliged. Rene’s method helped me understand the fundamentals and this really tops it off. Thanks fellas!!

1 Like

Hello Rene’
I seem to have run across an interesting problem. We have a customer who wants to use According to my quick calculations and online calculators we should get 512 subnets with 126 hosts per subnet. But I’m having an issue coming up with 512 subnets. I’m starting from zero and going up by a block size of 128 which I’m seeing as only 2 networks. What in the world am I doing wrong?


Hello Willie

The subnet will give you 128 IP addresses (126 host addresses) as you correctly stated. How many of these subnets you will have depends on the original address space that you are working with. That has not been defined, at least not in your post, so there’s no way to answer the question. However we can work backwards, and in order to get 512 subnets of 126 host addresses each, you would need to have the following original address space: which is the range of -

And the subnets you would get are the following:




How was this calculated? Lets look at the original address space, but with the last two octets in binary:

172.16.00000000.00000000 /16

Now by creating subnets of /25, you’re taking the last 7 bits (32-25) and using them as host bits:

172.16.00000000.00000000 /16

Now in order to get 512 of these subnets, we need 9 bits (2^9 = 512). So we use the next nine bits over for each subnet:

172.16.00000000.00000000 /16

Remember that in order to determine the total number of subnets you will get, you must first define your original address space.

I hope this has been helpful!


Thank you so much for your speedy reply. Sorry for asking an incomplete question but working backwards, you explained it completely.

1 Like

This topics teach us to divide the block 256 by the number of subnets to have the minor blocks, example 256 I want two subnets, so starts at 0 and next network will be 128… but what happens if I need 6 subnets, like the exercise below?
“Your manager would like you to subnet the network into six different networks.
What is your new subnet mask?”

I tried to get the third octect (256) divide by 6, but is not an integer number. Maybe should add an example like this in the lesson.

thanks you so much, waiting for the answer

Hello Victor

A network of has a range of 256 addresses. Now if you want to subnet this network into six smaller networks, then you can do one of two things. Ether create equal size subnets or create subnets of different sizes. In the second case, you can choose your sizes so that all IP addresses in the original network are being used. In the first case, you will have some unused subnets left over.

Now because this particular question doesn’t state that you must use all the original address space, nor does it say to use different sizes, I assume it means “create as many equal size subnets as are necessary to accommodate the six that you need”.

Now a range of 256 addresses can only be subnetted equally using particular numbers. Specifically:

  • 2 subnets of 128 addresses each
  • 4 subnets of 64 addresses each
  • 8 subnets of 32 addresses each
  • 16 subnets of 16 addresses each
  • 32 subnets of 8 addresses each
  • 64 subnets of 4 addresses each

Now which option gives you the largest number of addresses per subnet and can accommodate 6 networks? The 8 subnets of 32 addresses each is the correct answer, but you will have two unused subnets of 32 addresses each left over .

Consequently, you must divide by 8 in order to get enough networks to accommodate your needs.

I hope this has been helpful!


Hi Lazaros,

Great answer, thank you so much for your clear explanation!!!

1 Like

Hi Rene
For class A address , the subnet mask is . But I have seen for class A address , they use /24 which is Can u pls explain this?

Hello Ananth

Classful IP addressing is the method for subnetting that was initially used when IPv4 was initially created. This simplified subnetting since each specific range of addresses could only have a specific subnet size. So you knew that the address must have a subnet mask of and must have a subnet mask of

However, this scheme was not scalable, as many millions of addresses were wasted especially within class A subnets.

For this reason, classless subnetting was introduced. This is where the Variable Length Subnet Mask or VLSM comes in. This essentially means that the “rule” that states that class A addresses can only have a class A subnet is relaxed. You are allowed to further subnet a class A address.

This has allowed a more efficient usage of the IPv4 address space. That’s why you see class A address spaces with subnet masks other than /8. In a classless network environment, the terms Class A, Class B, and so on are now used only as a reference and not as a concept that constrains the subnet mask size.

I hope this has been helpful!