I often have to generate a sequence of IP addresses so I created this simple online utility that does it for me. It lets you generate however many sequential IPv4 addresses you need from the given range. It works in the browser and is powered by alien technology from the future.
Ip Addresses Generator Options
Ip Addresses Generator Examples (click to try!)
0.0.0.0 (0) 22.214.171.124 (252645135) 126.96.36.199 (505290270) 188.8.131.52 (757935405) 184.108.40.206 (1010580540) 220.127.116.11 (1263225675) 18.104.22.168 (1515870810) 22.214.171.124 (1768515945) 126.96.36.199 (2021161080) 188.8.131.52 (2273806215) 184.108.40.206 (2526451350) 220.127.116.11 (2779096485) 18.104.22.168 (3031741620) 22.214.171.124 (3284386755) 126.96.36.199 (3537031890) 188.8.131.52 (3789677025) 240.240.240.240 (4042322160) 255.255.255.255 (4294967295)
0a_00_00_00 0a_00_00_01 0a_00_00_02 0a_00_00_03 0a_00_00_04 0a_00_00_05 0a_00_00_06 0a_00_00_07 0a_00_00_08 0a_00_00_09 0a_00_00_0a 0a_00_00_0b 0a_00_00_0c 0a_00_00_0d 0a_00_00_0e 0a_00_00_0f 0a_00_00_10 0a_00_00_11 0a_00_00_12 0a_00_00_13 0a_00_00_14 0a_00_00_15 0a_00_00_16 0a_00_00_17 0a_00_00_18 0a_00_00_19 0a_00_00_1a 0a_00_00_1b 0a_00_00_1c 0a_00_00_1d 0a_00_00_1e 0a_00_00_1f 0a_00_00_20 0a_00_00_21 0a_00_00_22 0a_00_00_23 0a_00_00_24 0a_00_00_25 0a_00_00_26 0a_00_00_27 0a_00_00_28 0a_00_00_29 0a_00_00_2a 0a_00_00_2b 0a_00_00_2c 0a_00_00_2d 0a_00_00_2e 0a_00_00_2f 0a_00_00_30 0a_00_00_31
184.108.40.206 220.127.116.11b 18.104.22.168 140.120.4a.155 22.214.171.124 126.96.36.199 188.8.131.52 140.120.b5.51 184.108.40.206 220.127.116.11 18.104.22.168 140.120.15b.121 22.214.171.124 126.96.36.199
How Does This Ip Addresses Generator Work?
rangeEnd variables. There's also a
step variable that controls the distance between consecutive IP addresses. To create an output array of IPs, the program runs a
for loop with the initial expression
ip = rangeStart, condition expression
ip <= endRange, and increment expression
ip += step, and
ip value to array
ipList at each iteration step. When generating a specific count of IP addresses, the variables used are
step. In this case, the
ipList array is also populated via a regular
for loop with the counter
i going from
count. At each iteration step, the
startIp value is
pushed to the array and incremented by the
step value. As IP addresses consist of four decimal numbers (called octets), each between 0 and 255 and separated by dots, it's not easy to increment them directly. To make it easier to work with IPs, they are transformed from the dotted form
a.b.c.d to the single-integer form using the formula
intIp = aInt + bInt + cInt +dInt, where
aInt = a×256×256×256,
bInt = b×256×256,
cInt = c×256, and
dInt = d. After running the loop and filling the output array
ipList with IPs, they are converted back to the octet format through the reverse formula
(intIp>>24)&0xff + dot + (intIp>>16)&0xff + dot + (intIp>>8)&0xff + dot + intIp&0xff. The
dot variable can actually be any character and it can be changed in the octet separator option. The output IPs can also be converted to another base. In this case, the additional
BigNumber library is loaded. With this library, it's easy to convert each octet to a different base. First, each octet is converted into a big number by calling
new BigNumber(octet) and then it's converted to a string in the new base by calling
octet.toString(base). After all this, the IP addresses that were collected in the
ipList array are converted to plain text format by calling
ipList.join(ipSeparator) and are all printed to the output text box.
Created by Browserling
This ip addresses generator was created by me and my team at Browserling. Behind the scenes, it's actually powered by our web developer tools that are used by millions of people every month. Browserling itself is an online cross-browser testing service powered by alien technology. Check it out!
Secret message: If you love my tools, then I love you, too! Use coupon code TOOLLING to get a discount at my company.