Mpikirakira zana-rezo (IPv4 CIDR)
Ny IPv4 dia mampiasa ny IPv4 subnet, izay ahitana ny tambajotra, ny broadcast, ny mask, ny wildcard, ny host range ary ny count.
Manova ny valin'ny fanoratanao.
Momba ity kapila ity
This subnet calculator turns an IPv4 address and a CIDR prefix into the full structure of a subnet. An IPv4 address is 32 bits, usually written as four dot-separated octets like 192.168.1.10, and a CIDR prefix such as /24 splits those 32 bits into a network part (the leading bits, fixed for every host in the subnet) and a host part (the remaining bits, unique to each device). This calculator takes an address and a prefix length and derives the network address, broadcast address, subnet mask, wildcard mask and the range of usable host addresses, along with the IP class and total address count.
The size of a subnet is set by the prefix: a /n block holds 2^(32−n) addresses, of which two are reserved — the network address (all host bits 0, naming the subnet) and the broadcast address (all host bits 1, reaching every host). So a /24 has 2^8 = 256 addresses and 254 usable hosts, a /25 has 128 addresses and 126 usable hosts, and each extra prefix bit halves the block. As a worked example, 192.168.1.10/24 gives a network of 192.168.1.0, a broadcast of 192.168.1.255, a 255.255.255.0 mask, a 0.0.0.255 wildcard mask, and a usable host range of 192.168.1.1 to 192.168.1.254.
Subnetting is how networks are carved into manageable, secure segments — separating departments, sizing VLANs, planning address allocation and writing firewall and routing rules. The wildcard mask (the bitwise inverse of the subnet mask) is what Cisco access-control lists and OSPF use to match ranges of addresses. The /31 and /32 prefixes are special cases: /31 is used for point-to-point links with two usable addresses and no broadcast, and /32 describes a single host.
Fanontaniana matetika
Firy ny mpampiantrano ao anatin'ny zana-rezo iray?
A /n subnet has 2^(32−n) addresses, minus two reserved for the network and broadcast. A /24 has 256 addresses and 254 usable hosts.
Inona no atao hoe saron-tava wildcard?
A wildcard mask is the bitwise inverse of the subnet mask (255.255.255.0 → 0.0.0.255). Access-control lists and OSPF use it to match ranges of addresses.
Inona no fahasamihafana misy eo amin'ny adiresy tambajotra sy ny adiresy fampielezana?
Ny adiresy rezo (bit 0 ny mpizara rehetra) dia manome anarana ny zana-rezo; ny adiresy fandefasana (bit 1 ny mpizara rehetra) dia miditra amin'ny mpizara rehetra ao aminy. Tsy azo omena periferika ny iray amin'ireo.
Inona no dikan'ny tovon'ny CIDR (/24, /16)?
Io no isan'ny bit voalohany mamorona ny ampahany amin'ny rezo amin'ny adiresy. Ny tovon-teny lehibe kokoa dia midika hoe bit marobe kokoa amin'ny rezo ary bit vitsy amin'ny mpampiantrano, ka noho izany dia zana-rezo kely kokoa: /24 dia manome mpampiantrano 254, /25 dia manome 126, ary ny bit fanampiny dia manapaka ny ampahefatry ny vondrona.
Ahoana no fomba fizarazarako ny rezo ho zana-rezo kely kokoa?
Mividy bit amin'ny mpampiantrano amin'ny alalan'ny fampitomboana ny tovonteny. Ny fizarana ny /24 ho /25s roa dia hanome takelaka kelin'ny mpampiantrano 126; ny fidirana amin'ny /26 dia hanome takelaka kelin'ny mpampiantrano 62. Mampitombo avo roa heny ny isan'ny zana-rezo ary mampihena ny habeny amin'ny antsasaky ny habeny ny bit tovonteny iray.
Inona no atao hoe IP address?
The old classful scheme split addresses by their first octet: Class A (1–126), Class B (128–191) and Class C (192–223) for unicast, plus D for multicast and E reserved. CIDR replaced classes for allocation, but the calculator still reports the class the address falls in.
Inona no atao hoe zana-rezo /31 sy /32?
Ny /31 dia manana adiresy roa ihany fa tsy misy fampielezana, ampiasaina amin'ny fifandraisana teboka amin'ny teboka eo amin'ny routers. Ny /32 dia adiresy mpampiantrano tokana, mahazatra amin'ny loopbacks sy ny làlana mpampiantrano. Manatanteraka ireo tranga manokana roa ireo ny milina fanisana.
API — mampiasa io milina fanisana io avy amin'ny rindran'asa
Antsoy ho toy ny farany JSON malalaka ity milina fanisana ity - tsy mila famaha. Mandefa ireo sanda eo amin'ny sehatr'asa etsy ambany ho toy ny mpizaratry ny fanontaniana na JSON. Ny zavatra tsy voalaza dia mampiasa ny sanda tsotra efa nameno ity pejy ity; 400 ny sanda tsy fantatra, tsy aotra tsy misy feo. Vakio ny tahirin-kevitra API feno →
Endpoint
GET https://calculator.free/api/v1/subnet/
curl
curl "https://calculator.free/api/v1/subnet/?ip=192.168.1.10&cidr=24"
JavaScript fetch()
const r = await fetch(
"https://calculator.free/api/v1/subnet/?" + new URLSearchParams({
"ip": "192.168.1.10",
"cidr": "24"
}));
const data = await r.json();
console.log(data.results);
Ny voka-pikarohana dia natao ho an'ny torohevitra ankapobeny ihany, tsy torohevitra ara-bola, ara-pitsaboana na ara-bola.