ip calculator

Professional IPv4 IP & subnet calculator. Enter an IP and prefix or mask to get network, broadcast, host range, wildcard mask, class, and private/public status. Includes formulas, glossary, worked example, and FAQs.

IPv4 Calculator

Full original guide (expanded)

ip calculator

A precise IPv4 subnet tool for engineers, students, and IT pros. Enter an IP and prefix (or mask) to get the network, broadcast, host range, class, wildcard mask, and private/public status — with formulas and a worked example.

Results

Network
Broadcast
First Host
Last Host
Total Hosts
Usable Hosts
Subnet Mask
Wildcard Mask
Class
Private / Public
Binary & Hex view
IP (bin / hex)
Mask (bin / hex)

Authoritative Data Source & Methodology

Primary sources:

  • IETF RFC 791 (Internet Protocol) – Sept 1981
  • IETF RFC 950 (Internet Standard Subnetting Procedure) – Aug 1985
  • IETF RFC 4632 (Classless Inter-domain Routing, CIDR) – Aug 2006
All calculations strictly derive from the definitions and procedures in these RFCs. “Tutti i calcoli si basano rigorosamente sulle formule e sui dati forniti da questa fonte.”

The Formula Explained

Let prefix be \( p \) (0–32). Subnet mask has \( p \) ones followed by \( 32-p \) zeros.

Number of addresses: \( N = 2^{32-p} \)

Usable hosts (for \( 0<p<31 \)): \( U = \max(0,\,N - 2) \)

Network address: \( \text{net} = \text{IP} \,\&\, \text{mask} \)

Broadcast: \( \text{bcast} = \text{net} \,|\, \lnot \text{mask} \)

First host: \( \text{net} + 1 \) (if \( U>0 \))

Last host: \( \text{bcast} - 1 \) (if \( U>0 \))

Glossary of Variables

  • IP: IPv4 address (32-bit integer rendered as dotted decimal).
  • Prefix /p: Count of 1-bits in mask.
  • Subnet mask: 32-bit bitmask; ones for network, zeros for host.
  • Wildcard mask: Bitwise NOT of subnet mask.
  • Network: Bitwise AND of IP and mask.
  • Broadcast: Network OR wildcard.
  • Total hosts: All addresses in the subnet.
  • Usable hosts: Excludes network and broadcast when applicable.

How It Works: A Step-by-Step Example

Suppose IP = 192.168.1.10, prefix = /24.

  1. \( p=24 \Rightarrow N = 2^{8} = 256 \) addresses; \( U = 256-2 = 254 \) usable.
  2. Mask = 255.255.255.0. Wildcard = 0.0.0.255.
  3. Network = 192.168.1.0; Broadcast = 192.168.1.255.
  4. First host = 192.168.1.1; Last host = 192.168.1.254.

FAQ

What’s the difference between prefix and subnet mask?

The prefix (e.g., /24) is the count of 1-bits in the mask. The mask is the dotted-decimal representation of those bits (e.g., 255.255.255.0).

Why are network and broadcast not usable?

They identify the subnet itself (all host bits 0) and the broadcast address (all host bits 1). In point-to-point /31 and loopback /32 scenarios, special rules apply.

Is my address private?

Private ranges per RFC 1918: 10/8, 172.16/12, 192.168/16. The calculator flags these.

Do /31 subnets have usable hosts?

On point-to-point links, /31 uses both addresses and omits broadcast (RFC 3021). This tool reports usable hosts accordingly (0 traditional, but both addresses usable on P2P).

Does this support IPv6?

This page focuses on IPv4. Use a dedicated IPv6 calculator for 128-bit addressing and different rules.

What is the wildcard mask used for?

It’s the inverse of the subnet mask, commonly used in ACLs and some router configurations to match address ranges.

How is “class” determined?

Legacy classful ranges based on the first octet: A (0–127), B (128–191), C (192–223). Modern networks use CIDR rather than classful boundaries.

Last accuracy review:


Audit: Complete
Formula (LaTeX) + variables + units
This section shows the formulas used by the calculator engine, plus variable definitions and units.
Formula (extracted text)
Let prefix be \( p \) (0–32). Subnet mask has \( p \) ones followed by \( 32-p \) zeros. Number of addresses: \( N = 2^{32-p} \) Usable hosts (for \( 0<p<31 \)): \( U = \max(0,\,N - 2) \) Network address: \( \text{net} = \text{IP} \,\&\, \text{mask} \) Broadcast: \( \text{bcast} = \text{net} \,|\, \lnot \text{mask} \) First host: \( \text{net} + 1 \) (if \( U>0 \)) Last host: \( \text{bcast} - 1 \) (if \( U>0 \))
Variables and units
  • No variables provided in audit spec.
Sources (authoritative):
Changelog
Version: 0.1.0-draft
Last code update: 2026-01-19
0.1.0-draft · 2026-01-19
  • Initial audit spec draft generated from HTML extraction (review required).
  • Verify formulas match the calculator engine and convert any text-only formulas to LaTeX.
  • Confirm sources are authoritative and relevant to the calculator methodology.
Verified by Ugo Candido on 2026-01-19
Profile · LinkedIn

ip calculator

A precise IPv4 subnet tool for engineers, students, and IT pros. Enter an IP and prefix (or mask) to get the network, broadcast, host range, class, wildcard mask, and private/public status — with formulas and a worked example.

IPv4 Calculator

Results

Network
Broadcast
First Host
Last Host
Total Hosts
Usable Hosts
Subnet Mask
Wildcard Mask
Class
Private / Public
Binary & Hex view
IP (bin / hex)
Mask (bin / hex)

Authoritative Data Source & Methodology

Primary sources:

  • IETF RFC 791 (Internet Protocol) – Sept 1981
  • IETF RFC 950 (Internet Standard Subnetting Procedure) – Aug 1985
  • IETF RFC 4632 (Classless Inter-domain Routing, CIDR) – Aug 2006
All calculations strictly derive from the definitions and procedures in these RFCs. “Tutti i calcoli si basano rigorosamente sulle formule e sui dati forniti da questa fonte.”

The Formula Explained

Let prefix be \( p \) (0–32). Subnet mask has \( p \) ones followed by \( 32-p \) zeros.

Number of addresses: \( N = 2^{32-p} \)

Usable hosts (for \( 0<p<31 \)): \( U = \max(0,\,N - 2) \)

Network address: \( \text{net} = \text{IP} \,\&\, \text{mask} \)

Broadcast: \( \text{bcast} = \text{net} \,|\, \lnot \text{mask} \)

First host: \( \text{net} + 1 \) (if \( U>0 \))

Last host: \( \text{bcast} - 1 \) (if \( U>0 \))

Glossary of Variables

  • IP: IPv4 address (32-bit integer rendered as dotted decimal).
  • Prefix /p: Count of 1-bits in mask.
  • Subnet mask: 32-bit bitmask; ones for network, zeros for host.
  • Wildcard mask: Bitwise NOT of subnet mask.
  • Network: Bitwise AND of IP and mask.
  • Broadcast: Network OR wildcard.
  • Total hosts: All addresses in the subnet.
  • Usable hosts: Excludes network and broadcast when applicable.

How It Works: A Step-by-Step Example

Suppose IP = 192.168.1.10, prefix = /24.

  1. \( p=24 \Rightarrow N = 2^{8} = 256 \) addresses; \( U = 256-2 = 254 \) usable.
  2. Mask = 255.255.255.0. Wildcard = 0.0.0.255.
  3. Network = 192.168.1.0; Broadcast = 192.168.1.255.
  4. First host = 192.168.1.1; Last host = 192.168.1.254.

FAQ

What’s the difference between prefix and subnet mask?

The prefix (e.g., /24) is the count of 1-bits in the mask. The mask is the dotted-decimal representation of those bits (e.g., 255.255.255.0).

Why are network and broadcast not usable?

They identify the subnet itself (all host bits 0) and the broadcast address (all host bits 1). In point-to-point /31 and loopback /32 scenarios, special rules apply.

Is my address private?

Private ranges per RFC 1918: 10/8, 172.16/12, 192.168/16. The calculator flags these.

Do /31 subnets have usable hosts?

On point-to-point links, /31 uses both addresses and omits broadcast (RFC 3021). This tool reports usable hosts accordingly (0 traditional, but both addresses usable on P2P).

Does this support IPv6?

This page focuses on IPv4. Use a dedicated IPv6 calculator for 128-bit addressing and different rules.

What is the wildcard mask used for?

It’s the inverse of the subnet mask, commonly used in ACLs and some router configurations to match address ranges.

How is “class” determined?

Legacy classful ranges based on the first octet: A (0–127), B (128–191), C (192–223). Modern networks use CIDR rather than classful boundaries.

Last accuracy review:


Audit: Complete
Formula (LaTeX) + variables + units
This section shows the formulas used by the calculator engine, plus variable definitions and units.
Formula (extracted text)
Let prefix be \( p \) (0–32). Subnet mask has \( p \) ones followed by \( 32-p \) zeros. Number of addresses: \( N = 2^{32-p} \) Usable hosts (for \( 0<p<31 \)): \( U = \max(0,\,N - 2) \) Network address: \( \text{net} = \text{IP} \,\&\, \text{mask} \) Broadcast: \( \text{bcast} = \text{net} \,|\, \lnot \text{mask} \) First host: \( \text{net} + 1 \) (if \( U>0 \)) Last host: \( \text{bcast} - 1 \) (if \( U>0 \))
Variables and units
  • No variables provided in audit spec.
Sources (authoritative):
Changelog
Version: 0.1.0-draft
Last code update: 2026-01-19
0.1.0-draft · 2026-01-19
  • Initial audit spec draft generated from HTML extraction (review required).
  • Verify formulas match the calculator engine and convert any text-only formulas to LaTeX.
  • Confirm sources are authoritative and relevant to the calculator methodology.
Verified by Ugo Candido on 2026-01-19
Profile · LinkedIn

ip calculator

A precise IPv4 subnet tool for engineers, students, and IT pros. Enter an IP and prefix (or mask) to get the network, broadcast, host range, class, wildcard mask, and private/public status — with formulas and a worked example.

IPv4 Calculator

Results

Network
Broadcast
First Host
Last Host
Total Hosts
Usable Hosts
Subnet Mask
Wildcard Mask
Class
Private / Public
Binary & Hex view
IP (bin / hex)
Mask (bin / hex)

Authoritative Data Source & Methodology

Primary sources:

  • IETF RFC 791 (Internet Protocol) – Sept 1981
  • IETF RFC 950 (Internet Standard Subnetting Procedure) – Aug 1985
  • IETF RFC 4632 (Classless Inter-domain Routing, CIDR) – Aug 2006
All calculations strictly derive from the definitions and procedures in these RFCs. “Tutti i calcoli si basano rigorosamente sulle formule e sui dati forniti da questa fonte.”

The Formula Explained

Let prefix be \( p \) (0–32). Subnet mask has \( p \) ones followed by \( 32-p \) zeros.

Number of addresses: \( N = 2^{32-p} \)

Usable hosts (for \( 0<p<31 \)): \( U = \max(0,\,N - 2) \)

Network address: \( \text{net} = \text{IP} \,\&\, \text{mask} \)

Broadcast: \( \text{bcast} = \text{net} \,|\, \lnot \text{mask} \)

First host: \( \text{net} + 1 \) (if \( U>0 \))

Last host: \( \text{bcast} - 1 \) (if \( U>0 \))

Glossary of Variables

  • IP: IPv4 address (32-bit integer rendered as dotted decimal).
  • Prefix /p: Count of 1-bits in mask.
  • Subnet mask: 32-bit bitmask; ones for network, zeros for host.
  • Wildcard mask: Bitwise NOT of subnet mask.
  • Network: Bitwise AND of IP and mask.
  • Broadcast: Network OR wildcard.
  • Total hosts: All addresses in the subnet.
  • Usable hosts: Excludes network and broadcast when applicable.

How It Works: A Step-by-Step Example

Suppose IP = 192.168.1.10, prefix = /24.

  1. \( p=24 \Rightarrow N = 2^{8} = 256 \) addresses; \( U = 256-2 = 254 \) usable.
  2. Mask = 255.255.255.0. Wildcard = 0.0.0.255.
  3. Network = 192.168.1.0; Broadcast = 192.168.1.255.
  4. First host = 192.168.1.1; Last host = 192.168.1.254.

FAQ

What’s the difference between prefix and subnet mask?

The prefix (e.g., /24) is the count of 1-bits in the mask. The mask is the dotted-decimal representation of those bits (e.g., 255.255.255.0).

Why are network and broadcast not usable?

They identify the subnet itself (all host bits 0) and the broadcast address (all host bits 1). In point-to-point /31 and loopback /32 scenarios, special rules apply.

Is my address private?

Private ranges per RFC 1918: 10/8, 172.16/12, 192.168/16. The calculator flags these.

Do /31 subnets have usable hosts?

On point-to-point links, /31 uses both addresses and omits broadcast (RFC 3021). This tool reports usable hosts accordingly (0 traditional, but both addresses usable on P2P).

Does this support IPv6?

This page focuses on IPv4. Use a dedicated IPv6 calculator for 128-bit addressing and different rules.

What is the wildcard mask used for?

It’s the inverse of the subnet mask, commonly used in ACLs and some router configurations to match address ranges.

How is “class” determined?

Legacy classful ranges based on the first octet: A (0–127), B (128–191), C (192–223). Modern networks use CIDR rather than classful boundaries.

Last accuracy review:


Audit: Complete
Formula (LaTeX) + variables + units
This section shows the formulas used by the calculator engine, plus variable definitions and units.
Formula (extracted text)
Let prefix be \( p \) (0–32). Subnet mask has \( p \) ones followed by \( 32-p \) zeros. Number of addresses: \( N = 2^{32-p} \) Usable hosts (for \( 0<p<31 \)): \( U = \max(0,\,N - 2) \) Network address: \( \text{net} = \text{IP} \,\&\, \text{mask} \) Broadcast: \( \text{bcast} = \text{net} \,|\, \lnot \text{mask} \) First host: \( \text{net} + 1 \) (if \( U>0 \)) Last host: \( \text{bcast} - 1 \) (if \( U>0 \))
Variables and units
  • No variables provided in audit spec.
Sources (authoritative):
Changelog
Version: 0.1.0-draft
Last code update: 2026-01-19
0.1.0-draft · 2026-01-19
  • Initial audit spec draft generated from HTML extraction (review required).
  • Verify formulas match the calculator engine and convert any text-only formulas to LaTeX.
  • Confirm sources are authoritative and relevant to the calculator methodology.
Verified by Ugo Candido on 2026-01-19
Profile · LinkedIn
Formulas

(Formulas preserved from original page content, if present.)

Version 0.1.0-draft
Citations

Add authoritative sources relevant to this calculator (standards bodies, manuals, official docs).

Changelog
  • 0.1.0-draft — 2026-01-19: Initial draft (review required).