Discuvr IP Subnet Calculator

Office & Data

CSV to Excel Paste CSV and see it as a spreadsheet instantly, with numbers, dates and IDs typed the way Excel should hold them. Download a clean .xlsx only when you want it. Sign PDF Sign a PDF in your browser - draw, type or upload your signature, place it on any page, add the date, and download the signed copy. The file never leaves your device. Redact Permanently redact PDF, Word, Excel, PowerPoint, text and image files. Matches and boxes are removed from the file itself, not covered up, and the result is checked again before you download it. What is my IP See the public IP address websites see when you connect, whether it is shared (CGNAT) or private, and what else your browser reveals. Case Converter & Line Tools Change text to UPPER, lower, Title or Sentence case, turn names into camelCase or snake_case, and remove duplicate lines or sort a list. Text Compare Paste two versions of a text to see every added, removed and changed line, with the changed words highlighted.

Writing & Proposals

Tone Polish Reformat what you wrote with proper grammar, structure and articulation - in your own voice. One paste, one reply, no chat session. Freelance Proposal Generator Describe a client problem and get a scoped, priced, ready-to-send freelance proposal in seconds.

Legal & Compliance

IP Law Q&A Chatbot Ask questions about Indian IP law - trade marks, patents, copyright, designs and more, with the web search results it used listed above each answer. Patent FER Reply Generator Paste the objections from a First Examination Report to draft a structured reply, or upload a draft for an IP risk review. Government Scheme Eligibility Finder Answer a short set of questions once. Sign in and we save your answers, so you can check which central government schemes you may qualify for without retyping them.

Privacy & Security

Website Security Scan Scan a domain for real, reproducible security weaknesses. Every finding carries the observation behind it and the command to verify it yourself. Image Scrub See exactly what your photo reveals about you - GPS, camera serial, your name - then strip it. Crop, resize, blur faces and convert, all without the image being stored anywhere.

Developer Tools

JSON Formatter Beautify, minify and validate JSON in one paste - with the exact line and column when it will not parse, and a count of what is actually in the document. Python Formatter Reformat Python the way Black would, with the line length and quote handling you choose - and a count of exactly how many lines changed. HTML Viewer Paste HTML and see it rendered live in a sandbox, at phone, tablet or desktop width - with beautify, minify, a console for scripts and a report of what is broken in the markup. IP Subnet Calculator Enter CIDR notation or an IP with a netmask and get the network address, broadcast address, usable host range and total address count instantly. Encode / Decode Encode or decode Base64, Base64URL, URL percent-encoding, HTML entities and hex as you type, with full UTF-8 support. Unix Timestamp Converter Convert a Unix epoch timestamp in seconds, milliseconds, microseconds or nanoseconds to a date in UTC or a major world time zone, and a date back to a timestamp. System Diagram Maker Type arrows like User -> API -> Database and get a laid-out architecture or flow diagram. Fold groups into one box for the big picture, number the steps for a detailed flow.

AI Workbench

AI Playground Compare responses from multiple LLM providers side by side in real time. Bring your own API keys. Agent Playground Experiment with AI agents that use tools - web search, a calculator, URL fetching - across multiple providers.

Learning

Study Buddy An interview-prep coach for top tech jobs, from the first study day to an accepted offer: a plan across DSA, LLD, system design, behavioural and AI-assisted coding, mock interviews, a resume review, an applications tracker and offer comparison.

Everyday Helpers

QR Code Generator Create QR codes from text, URLs, WiFi credentials or contact info - as PNG images or SVG vectors, with the error correction level you choose. Unit Converter Convert between length, weight, temperature, volume, speed, area and energy units instantly - 40+ unit types with instant results. Password Generator Generate a random password with cryptographically secure randomness, tune its length and character types, and see its strength in bits of entropy. Word Counter & Readability Analyzer Count words, characters, sentences and paragraphs, estimate reading time, and score readability - with true character-based counting for Chinese, Japanese, Korean and Thai text. Age / Date Difference Calculator Find someone's exact age, or the exact difference between any two dates - years, months and days, plus the total number of days and weeks. Date Difference Calculator Count the days, weeks, months and working days between two dates, or add and subtract days from a date. Percentage Calculator Calculate X% of Y, what percent one number is of another, percentage increase or decrease between two numbers, or reverse percentage - four common calculations in one tool. SIP Calculator See what a monthly investment grows to, with a yearly step-up, a starting lump sum and inflation, or find the monthly amount a goal needs. BMI Calculator Calculate your Body Mass Index (BMI) from height and weight, in metric or imperial units, classified against the WHO adult categories - underweight, normal, overweight, obese.
Sign in Get started
All toolsDeveloper Tools

IP Subnet Calculator

Compute the network address, broadcast address, usable host range and more from CIDR notation or an IP paired with a netmask.

Leave this blank if you already included a prefix, like /24, above.

Try an example

IP range to CIDR

Enter the first and last address of a range to get the smallest set of CIDR blocks that covers it exactly, for firewall rules and allow lists.

IPv4 prefix cheat sheet

Prefix Netmask Wildcard mask Total addresses Usable hosts
/32 255.255.255.255 0.0.0.0 1 1
/31 255.255.255.254 0.0.0.1 2 2
/30 255.255.255.252 0.0.0.3 4 2
/29 255.255.255.248 0.0.0.7 8 6
/28 255.255.255.240 0.0.0.15 16 14
/27 255.255.255.224 0.0.0.31 32 30
/26 255.255.255.192 0.0.0.63 64 62
/25 255.255.255.128 0.0.0.127 128 126
/24 255.255.255.0 0.0.0.255 256 254
/23 255.255.254.0 0.0.1.255 512 510
/22 255.255.252.0 0.0.3.255 1024 1022
/21 255.255.248.0 0.0.7.255 2048 2046
/20 255.255.240.0 0.0.15.255 4096 4094
/19 255.255.224.0 0.0.31.255 8192 8190
/18 255.255.192.0 0.0.63.255 16384 16382
/17 255.255.128.0 0.0.127.255 32768 32766
/16 255.255.0.0 0.0.255.255 65536 65534
/15 255.254.0.0 0.1.255.255 131072 131070
/14 255.252.0.0 0.3.255.255 262144 262142
/13 255.248.0.0 0.7.255.255 524288 524286
/12 255.240.0.0 0.15.255.255 1048576 1048574
/11 255.224.0.0 0.31.255.255 2097152 2097150
/10 255.192.0.0 0.63.255.255 4194304 4194302
/9 255.128.0.0 0.127.255.255 8388608 8388606
/8 255.0.0.0 0.255.255.255 16777216 16777214
/7 254.0.0.0 1.255.255.255 33554432 33554430
/6 252.0.0.0 3.255.255.255 67108864 67108862
/5 248.0.0.0 7.255.255.255 134217728 134217726
/4 240.0.0.0 15.255.255.255 268435456 268435454
/3 224.0.0.0 31.255.255.255 536870912 536870910
/2 192.0.0.0 63.255.255.255 1073741824 1073741822
/1 128.0.0.0 127.255.255.255 2147483648 2147483646
/0 0.0.0.0 255.255.255.255 4294967296 4294967294

Nothing you enter is stored - this is pure arithmetic, computed and returned in the same request.

About IP Subnet Calculator

A CIDR block or an IP address paired with a netmask hides a handful of facts you usually need right away: the network and broadcast address, how many hosts actually fit, and which addresses are the first and last you can assign. This works them all out instantly, for IPv4 and IPv6 alike, entirely as arithmetic - nothing you enter is looked up, logged or stored.

What it does

  • Accepts CIDR notation (192.168.1.0/24), an IPv6 prefix (2001:db8::/32), or a bare IP with a separate dotted netmask.
  • Masks off host bits automatically, so pasting a host address like 192.168.1.5/24 still gives the right network.
  • Reports network address, broadcast address (IPv4), netmask, wildcard mask, prefix length, total addresses and usable host count.
  • Gives the first and last usable host address directly, without listing every address in between.
  • Flags whether a network falls in private, carrier-grade NAT, loopback or other reserved address space.
  • Handles a single host (/32 or /128) and a point-to-point link (/31) correctly, where every address is usable.
  • Also converts an IP range (first and last address) into the smallest exact list of CIDR blocks, and lists every IPv4 prefix from /32 to /0 in a cheat sheet.

How it works

  1. 1 Paste CIDR notation, or an IP address plus a separate netmask.
  2. 2 Press Calculate.
  3. 3 Read off the network address, host range and address count.

Why usable hosts is not the same as total addresses

An IPv4 network reserves its first address for the network itself and its last for a broadcast, so a /24 has 256 total addresses but only 254 you can assign. A /31 and a /32 are the exceptions: RFC 3021 makes both addresses of a /31 usable for a point-to-point link, and a /32 is a single host route with nothing to reserve. IPv6 has no broadcast address, so this tool counts every address in an IPv6 subnet as usable, including the network address. Two IPv6 details it does not subtract: RFC 4291 makes the all-zeros address of each subnet the Subnet-Router anycast address, and RFC 6164 recommends a /127 for links between routers.

Worked examples

10.20.30.40/22 belongs to network 10.20.28.0 with netmask 255.255.252.0, wildcard 0.0.3.255 and broadcast 10.20.31.255: 1,024 addresses, 1,022 usable hosts from 10.20.28.1 to 10.20.31.254. 172.16.5.4/27 gives network 172.16.5.0, broadcast 172.16.5.31 and 30 usable hosts (172.16.5.1 to 172.16.5.30). In the range converter, 192.168.1.10 to 192.168.1.40 is 31 addresses and needs five blocks: 192.168.1.10/31, 192.168.1.12/30, 192.168.1.16/28, 192.168.1.32/29 and 192.168.1.40/32. A range that lines up with a prefix, such as 10.0.0.0 to 10.0.3.255, collapses to the single block 10.0.0.0/22.

Why a /0 or a huge IPv6 prefix still returns instantly

A /0 network holds every IPv4 address there is, and a large IPv6 prefix can hold more addresses than there are stars in the observable universe. The counts and bounds here come from direct arithmetic on the network's own numeric range, never from stepping through each address one at a time, so the size of the network never changes how long the answer takes.

What "reserved" means here

Beyond the everyday private ranges (10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16), the classification also covers carrier-grade NAT space (100.64.0.0/10) that some providers and mesh VPNs use internally, and a handful of IANA special-purpose ranges reserved for protocol infrastructure like AS112 and 6to4 relays - none of which are addresses you would expect to see on an ordinary public website.

Questions

Does this tool look up or connect to the address I enter?

No. It only parses the text you typed and does arithmetic on it, so nothing is resolved or fetched. The address itself is never logged or stored; the site records only a usage event saying whether the input was valid and whether it was IPv4 or IPv6.

What happens if I enter a host address instead of a network address, like 192.168.1.5/24?

The host bits are masked off automatically, so you get the same result as entering 192.168.1.0/24 - the network your address actually belongs to.

Does it support IPv6?

Yes, any prefix length from /0 to /128. IPv6 has no broadcast address, so the tool reports every address in the subnet as usable, including the network address. In practice the all-zeros address of a subnet is the Subnet-Router anycast address (RFC 4291), so do not assign it to a host.

Why does a /31 or /32 network show every address as usable?

A /32 is a single host with no network or broadcast address to reserve. A /31 is the two-address point-to-point link defined in RFC 3021, where both addresses are usable rather than one being reserved as a broadcast address.

Can I enter an IP and a netmask instead of CIDR notation?

Yes. Leave the first field as a bare IP address and put a dotted netmask like 255.255.255.0 in the second field instead of a /prefix. A Cisco-style wildcard mask such as 0.0.0.255 works there too and gives the same /24. A non-contiguous mask like 255.0.255.0 is refused, because it describes no single CIDR block.

How do I split a /24 into smaller subnets?

The tool does not split for you, but the arithmetic is short: each bit you add to the prefix doubles the number of subnets and halves their size. A /24 (256 addresses) splits into two /25s of 128, four /26s of 64 or eight /27s of 32. The four /26s of 192.168.10.0/24 start at .0, .64, .128 and .192, and each has 62 usable hosts, so 192.168.10.64/26 runs from .65 to .126 with .127 as its broadcast. Enter each block here to check its range, and pick the size from the prefix table on this page: 50 devices need a /26, because a /27 has only 30 usable hosts.

Which IP address ranges are private?

Three IPv4 ranges are private under RFC 1918: 10.0.0.0/8 (10.0.0.0 to 10.255.255.255, 16,777,216 addresses), 172.16.0.0/12 (172.16.0.0 to 172.31.255.255, 1,048,576 addresses) and 192.168.0.0/16 (192.168.0.0 to 192.168.255.255, 65,536 addresses). A common slip is 172.32.0.0 and above, which is public: only 172.16 to 172.31 is private. Three more ranges are not routed on the public internet either: 100.64.0.0/10 is carrier-grade NAT space for providers (RFC 6598), 169.254.0.0/16 is link-local, the address a device gives itself when DHCP fails (RFC 3927), and 127.0.0.0/8 is loopback. In IPv6, unique local addresses fc00::/7 (RFC 4193, in practice fd00::/8) play the private role and fe80::/10 is link-local. Enter any block here and the result labels it Private, Carrier-grade NAT, Link-local, Loopback or Public.

What is a wildcard mask and where do I use it?

A wildcard mask is the netmask with every bit flipped, so each octet is 255 minus the netmask octet: 255.255.255.0 (/24) becomes 0.0.0.255 and 255.255.255.192 (/26) becomes 0.0.0.63. A 0 bit means that bit must match and a 1 bit means any value is allowed. Cisco IOS access lists and OSPF network statements take a wildcard instead of a netmask: access-list 10 permit 192.168.10.64 0.0.0.63 matches 192.168.10.64 to 192.168.10.127, and network 10.0.0.0 0.0.0.255 area 0 enables OSPF on interfaces in 10.0.0.0/24. A netmask typed where a wildcard belongs matches the wrong addresses, so copy the Wildcard mask row from the result or from the prefix table on this page.