Kubernetes CPU & Memory Unit Converter
Type a CPU or memory quantity the way it appears in a pod spec, such as 250m or 512Mi, and see it in cores, millicores, bytes, and binary and decimal units. It flags the suffix mistakes that quietly give a container 1,000 times too much CPU or a few bytes of memory.
Free, no signup. Runs entirely in your browser; nothing you enter is sent anywhere.
Write it as 250m
| Binary (1024) | Decimal (1000) |
|---|---|
| 524288Ki | 536870.912k |
| 512Mi | 536.871M |
| 0.5Gi | 0.537G |
| 0Ti | 0.001T |
resources:
requests:
cpu: 250m
memory: 512MiCPU: cores and millicores
One CPU in Kubernetes is one vCPU or hyperthread. 1000m (millicores) equals 1, so 250m is a quarter of a core and 0.5 is the same as 500m. The smallest unit is 1m. The classic slip is a capital M: 500M means 500 million cores, and the pod sits in Pending forever because no node is that big.
Memory: Mi vs M
Mi, Gi and Ti are powers of 1024; M, G and T are powers of 1000. 512M is about 4.9% less than 512Mi, and the gap grows to 7.4% at G and nearly 10% at T. Monitoring tools and kubectl top usually report binary units, so writing limits in Mi/Gi avoids an off-by-a-few-percent surprise right before an OOMKilled. A lowercase m on memory means milli-bytes, which is never what anyone wants.
Once the units are right, size the numbers with the Kubernetes resource request calculator.
Questions people ask
What does 100m CPU mean in Kubernetes?
100 millicores, or one tenth of a CPU core. The container is guaranteed about 10% of one core's time when it requests 100m, and is throttled at that rate if 100m is its limit.
Should I use Mi or M for Kubernetes memory?
Use Mi and Gi. They match how the kernel, cgroups and most dashboards count memory (powers of 1024). M and G are valid but decimal, so 1G is about 7% smaller than 1Gi.
Is 0.5 the same as 500m?
Yes. Kubernetes normalises both to 500m. Values finer than 1m are rounded up, so 0.0001 becomes 1m.