Module 1 · Addresses, Subnets and Packets · Lesson 2 of 9

Subnetting step by step

Split 192.168.10.0/24 into four equal subnets and record network, host range, broadcast and mask for each.

In this lesson · about 32 minutes

  • Convert between prefix length and subnet mask
  • Divide a network into equal subnets by borrowing host bits
  • Find the network, usable host range and broadcast of any subnet

Whiteboard · watch and try

Cutting the street into four blocks

Press Play. The tutor splits 192.168.10.0/24 into four equal pieces, slowly.

6 steps
Press Play and the tutor will talk you through it while writing on the board. Pause any time to write on the board yourself.

Tip: press Pause, then use the pen to work along on the board. Space plays and pauses; Ctrl+Z undoes your last mark.

An IPv4 address is 32 bits, written as four numbers from 0 to 255. The prefix length (the /24 part) says how many of those bits name the network. The rest name the host.

PrefixMaskAddressesUsable hosts
/24255.255.255.0256254
/25255.255.255.128128126
/26255.255.255.1926462
/27255.255.255.2243230
/28255.255.255.2401614

Each time the prefix grows by one, the block halves. For ordinary IPv4 subnets you subtract two from the address count for usable hosts: the first address is the network address and the last is the broadcast address. (Point-to-point /31 links and single-host /32 routes are special cases and don't follow this rule.)

The three-step method

  1. How many bits to borrow? To make N equal subnets, borrow enough host bits that 2bits ≥ N. Four subnets need 2 bits (2² = 4).
  2. Block size: 256 minus the last mask number, or simply 2(32 − prefix). A /26 has a block size of 64.
  3. Count up by the block size. Each subnet starts where the last one ended. The broadcast is one less than the next network.

Try it · watch it move

Slice a network into equal pieces

Choose how many pieces to cut, then click any square to see which block it belongs to and whether a device can use it. Watch the mask and block size change together.

Cut 192.168.10.0/24 into

The 256 addresses 192.168.10.0 – .255, one square each

N = network address (the name of the block) · B = broadcast ("everyone in this block") · click any square

The answer table

Prefix/26Mask255.255.255.192Addresses per piece64Usable for devices62
.0/26hosts .1–.62bc .63
.64/26hosts .65–.126bc .127
.128/26hosts .129–.190bc .191
.192/26hosts .193–.254bc .255
192.168.10.130 is in piece 3: 192.168.10.128/26. It's a normal host address: a device can use it. Each time you double the pieces, each piece halves: think of cutting a pizza.

Worked example

Practice challenge 01: four equal subnets

Divide 192.168.10.0/24 into four equal subnets. Record the network, usable host range, broadcast address and mask of each.
    Step 0 of 8

    Performance-based question (PBQ)

    Fill in the subnet table

    The office network 10.20.30.0/24 is being split into eight equal subnets for different teams. Your manager has started a table and asks you to finish it.

    Pick the correct value for each row.

    • New prefix length for 8 equal subnets
    • Subnet mask
    • Addresses per subnet
    • Usable hosts per subnet
    • Network address of the third subnet
    • Broadcast address of the third subnet
    • Usable range of the fourth subnet
    • Broadcast address of the last subnet
    0 of 8 answered

    Check your understanding0 of 4 correct

    Question 1

    1.What prefix divides a /24 into four equal networks?

    Question 2

    2.Which address is the broadcast for the subnet 192.168.10.128/26?

    Question 3

    3.A team needs 25 hosts on one subnet, using as few addresses as possible. Which prefix fits?

    Question 4

    4.Is 10.20.30.64 a valid host address in 10.20.30.64/27?

    Quiz score: 0 of 4

    Tip: answer every quiz question correctly first.

    Noviq Academy is free and for learning. Every lab here is simulated with synthetic data and private lab addresses. Only capture traffic and test networks that you own or have written permission to test. Wireshark and pfSense are trademarks of their owners; this course is independent of them.