Skip to main content
IP Range CalculatorPRO
Diagnostics, Generators & UtilitiesInstant Client-Side Tool

Random Address Sampler

Sample addresses within supplied ranges.

Random Address Sampler: inputs and results

Enter an IP address, CIDR prefix, or range. Then check its first and last address below.

Quick presets:

Calculated Boundaries & ParametersReady

Network Address192.168.1.0
Broadcast Address192.168.1.255
First Usable Host192.168.1.1
Last Usable Host192.168.1.254
Subnet Mask255.255.255.0
Wildcard Mask0.0.0.255
Total Addresses256
Usable Host Range254

Key Capabilities

  • •100% Client-Side: Zero telemetry or server latency.
  • •RFC Compliant: Exact 32-bit and 128-bit integer precision.
  • •Quick Copy: Instant access to CIDR, mask, and range bounds.
  • •Cross-Platform: Works on desktop, tablet, and mobile browsers.

How Random Address Sampler Works?

The Random Address Sampler works by drawing random integer offsets inside each supplied range and converting each offset into an address, with every address in the range equally likely.

  1. Enter the ranges

    Type 1 or more ranges or prefixes, such as 10.0.0.0/16.

  2. Set the sample size

    Choose how many addresses to draw, such as 10.

  3. Draw offsets

    Each draw picks a random integer from 0 to size − 1. Multiple ranges are weighted by size.

  4. Output the sample

    The sampler prints the addresses, with an option to avoid repeats.

Random Address Sampler Formula

The Random Address Sampler formula is Address = Start + floor(r × Size), where r is a uniform random number in [0, 1).

Single draw

A = S + floor(r × N)

N = range size.

Range weight

P(range_i) = N_i ÷ Σ N

Larger ranges receive more draws.

Without repeats

max sample = Σ N

Sampling stops when the pool is empty.

Seeded runs

same seed → same sample

Reproducible test data.

Worked example: 1 draw from 10.0.0.0/16

Size = 65,536
r = 0.4321 → offset = floor(0.4321 × 65,536) = 28,317
28,317 = 110 × 256 + 157
Address = 10.0.110.157

Random Address Sampler Conversion Table

The Random Address Sampler conversion table shows a seeded sample of 10 addresses drawn from 10.0.0.0/16, with the offset of each address.

#Sampled AddressOffset in Range
110.0.149.1838,162
210.0.133.1834,066
310.0.234.5759,961
410.0.178.22345,791
510.0.192.20149,353
610.0.176.12645,182
710.0.133.10334,151
810.0.38.2219,949
910.0.12.1433,215
1010.0.57.23914,831

What is Random Address Sampler?

The Random Address Sampler is a tool that picks random IP addresses from supplied ranges, with every address equally likely to be chosen.

Sampling gives a fair subset of a large address space. Testing 20 random addresses from a /16 gives a quick view of firewall or routing behavior across the whole block without enumerating 65,536 addresses.

Seeded sampling produces the same addresses on every run, which keeps test results reproducible.

What are the uses of Random Address Sampler?

There are 4 main uses of the Random Address Sampler, including spot-check testing, load test data, and audit sampling.

  • Spot-checking firewall rules

    Random addresses from an allowed range are tested against the rule base.

  • Generating load test traffic

    Load tests use random source addresses to spread connections across a range.

  • Sampling for audits

    Auditors pick random addresses to compare IPAM records with live devices.

  • Creating anonymized examples

    Documentation uses random addresses from 192.0.2.0/24 instead of real hosts.