子網路計算機
開發者工具依IP/CIDR計算遮罩、廣播位址與可用主機數
答案速覽
Subnet Calculator: IP/CIDR to mask, broadcast and usable hosts. Mask /n = first n bits set · Network = IP AND mask · Broadcast = network OR wildcard.
網段範圍
192.168.1.1 ~ 192.168.1.254
254 可用主機 / 256 總位址
網路位址192.168.1.0
廣播位址192.168.1.255
子網路遮罩255.255.255.0
萬用字元遮罩0.0.0.255
二進制檢視
- 1IP: 11000000.10101000.00000001.01100100
- 2Mask: 11111111.11111111.11111111.00000000(前 24 位为 1)
- 3網路位址 = IP 與遮罩按位與 = 192.168.1.0
- 4廣播位址 = 網路位址 或 通配符 = 192.168.1.255
常用 CIDR 速查
| CIDR | 遮罩 | 可用主機 | 典型用途 |
|---|---|---|---|
| /8 | 255.0.0.0 | 16,777,214 | Class A |
| /16 | 255.255.0.0 | 65,534 | Class B / large LAN |
| /24 ← | 255.255.255.0 | 254 | Class C / most common |
| /25 | 255.255.255.128 | 126 | Half C |
| /26 | 255.255.255.192 | 62 | Small department |
| /27 | 255.255.255.224 | 30 | Small team |
| /30 | 255.255.255.252 | 2 | Point-to-point link |
💡 記住 2 的冪表:/24=256、/25=128、/26=64、/27=32、/28=16、/29=8、/30=4 個位址。私網段(RFC1918):10.0.0.0/8、172.16.0.0/12、192.168.0.0/16——公網不可路由。/31 點對點鏈路(RFC3021)無網路/廣播位址,兩個位址都可用。
這個工具對你有幫助嗎?
怎麼用
- Paste or type content: drop code/text into the Subnet Calculator or fill the parameters.
- Choose mode/options: switch format, rules or processing as needed.
- Live output: results appear instantly — nothing is submitted, data stays in your browser.
- One-click copy: copy the output straight into your development environment.
核心要點
- Subnet Calculator is a free online developer tool — open and use, no sign-up.
- All calculations run locally in your browser; your data never leaves the device.
- Key capability: IP/CIDR to mask, broadcast and usable hosts.
- Results come with formulas and reference tables so you can verify every number.
原理與公式
IPv4 subnetting
Mask /n = first n bits set · Network = IP AND mask · Broadcast = network OR wildcard
Usable hosts = 2^(32−n) − 2
/24 = 254 · /26 = 62 · /27 = 30 hosts
常見問題
How do I use the Subnet Calculator?
Open the page and fill in the input fields — results update automatically. IP/CIDR to mask, broadcast and usable hosts.
Are the results accurate?
Yes. Standard formulas and conversion factors are used and verified.
Is it free? Do I need to sign up?
Completely free. No registration, login or download required.
Does it work on mobile?
Yes. The responsive design works on phones, tablets and desktops.
Is my data saved?
No. Everything runs locally in your browser.
相關工具
相關指南
來源與更新
Based on RFC 4648, ECMA-262 and related specifications. Last updated: 2025-07
權威來源:
最近更新:
本頁公式與內容經YiJianSuan團隊覆核,僅供學習參考,實際業務請以官方口徑為準。
內容由YiJianSuan編輯團隊維護並定期覆核,更新與審核流程詳見編輯規範.
引用本頁: YiJianSuan. 子網路計算機[EB/OL]. https://www.yijiansuan.com/zh-TW/c/dev/subnet
本工具提供的結果僅供參考,不構成任何專業建議,請以官方核算為準。