Units of measurement
Stay organized with collections
Save and categorize content based on your preferences.
Put a nonbreaking space between the number and the unit.
Spaces in units of measurement
For most units of measurement, when you specify a number with the unit, use a
nonbreaking space between the number and the unit. This guidance applies in both
HTML and Markdown.
For guidance about when to spell out units, see the
Abbreviations page.
Recommended: 64 GB
(64 GB)
Recommended: 25 mm
(25 mm)
Not recommended: 64 GB
Not recommended: 64GB
However, when the unit of measure is money or percent or degrees of an angle,
don't use a space. For more information, see Currency.
Recommended: $10
Recommended: £25
Recommended: 65%
Recommended: 180°
For degrees of temperature, don't use a space before the degree symbol, but
do use a nonbreaking space between the degree symbol and the abbreviation for
the temperature scale (F or C). For Kelvin temperatures, leave
out the degree symbol but use a nonbreaking space before the K.
Recommended: 50° C
(50° C)
Recommended: 300 K
(300 K)
When a number and unit of measurement combine to modify a noun, don't hyphenate unless
the hyphen is needed for clarity.
Recommended:
200 GB disk
(200 GB disk)
Ranges of numbers with units
In a range of numbers, repeat the unit for each number. Unit includes both symbols (like
the degree symbol (º)) and abbreviations (like MB for megabytes) but not nouns
(like file). For more information, see
Range of numbers.
Use the word to between the numbers, rather than a hyphen. A hyphen
can be misinterpreted as a subtraction sign.
Recommended: -40° C to 85° C
Not recommended: -40-85° C
Hyphens with multiplied units
When the components of a unit of measurement are multiplied by each other,
hyphenate them.
Recommended: 5 vCPU-hours
Recommended: 40 person-hours
Use k to indicate thousands
In some contexts, it might be appropriate to indicate thousands of something by
following a number with a lowercase k. If you do that, then follow these
guidelines:
- Don't put a space between the number and k.
- Add a noun to indicate what the number measures, and to make clear that
you're not using k as an abbreviation for kilobytes.
Recommended: On this plan, you are
limited to 55k download operations and 20k upload operations per day.
Currency
If you're writing about monetary amounts, make sure that the reader knows what
currency you're referring to. For example, the dollar sign—the $
symbol—can refer to US dollars, Canadian dollars, Mexican pesos, and several
other currencies.
If there's any possibility of ambiguity, use a currency indicator before
the amount. For details, see section 9.20 and following in the Chicago
Manual of Style, 17th edition.
Recommended: US$10
Rates
Use per instead of the division slash (/) when space permits.
It's OK to use the division slash when space is limited,
such as in a table with small cells.
Shorten per to p only for well-established abbreviations for
rate units, such as Gbps for gigabits per second or
MBps for megabytes per second.
Recommended: requests per day
Not recommended: requests/day
Recommended: Gbps
Not recommended: Gb/s
Decimal and binary units
Use the same system to measure bytes as the technology that you're documenting.
Don't use MB if you mean MiB, or GB if you mean GiB. The following
table lists common types of
decimal and binary units:
Decimal units |
Binary units |
kB (kilobyte, or 1000 bytes) |
KiB (kibibyte, or 1024 bytes) |
MB (megabyte, or 10002 bytes) |
MiB (mebibyte, or 10242 bytes) |
GB (gigabyte, or 10003 bytes) |
GiB (gibibyte, or 10243 bytes) |
For more information about abbreviating measurement terms, see
When to spell out a term.
Provide visuals for math concepts
Accompany math concepts and numerals with
diagrams or other images
to support comprehension. For example, if comparing statistics, consider illustrating percentages in
a pie chart or a bar graph.
Accompany numerical concepts with real-world practical implications
Accompany numerical concepts with real-world practical implications to provide tangible meaning.
For example, if using a feature incurs additional fees, add a link to pricing calculator.
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-07-08 UTC.
[null,null,["Last updated 2025-07-08 UTC."],[[["\u003cp\u003eUse a nonbreaking space (\u003ccode\u003e \u003c/code\u003e) between numbers and most units of measurement (e.g., \u003ccode\u003e64 GB\u003c/code\u003e), except for currency, percent, or degrees of an angle.\u003c/p\u003e\n"],["\u003cp\u003eFor temperature, use \u003ccode\u003e° C\u003c/code\u003e or \u003ccode\u003e° F\u003c/code\u003e, and for Kelvin, use \u003ccode\u003e K\u003c/code\u003e (e.g., \u003ccode\u003e50° C\u003c/code\u003e, \u003ccode\u003e300 K\u003c/code\u003e).\u003c/p\u003e\n"],["\u003cp\u003eIn ranges, repeat the unit for each number and use "to" instead of a hyphen (e.g., -40° C to 85° C).\u003c/p\u003e\n"],["\u003cp\u003eWhen documenting technology, ensure you use the correct system for bytes, distinguishing between decimal (kB, MB, GB) and binary (KiB, MiB, GiB) units.\u003c/p\u003e\n"],["\u003cp\u003eUse visuals like diagrams or charts to enhance comprehension of math concepts and accompany numerical concepts with real-world implications whenever possible.\u003c/p\u003e\n"]]],["Use a nonbreaking space between a number and its unit (e.g., `64 GB`), except for money, percent, or angle degrees. For temperature degrees, use a nonbreaking space between the degree symbol and the scale (e.g., `50° C`). In number ranges, repeat the unit for each number and use \"to\" instead of a hyphen. Hyphenate multiplied units (e.g., vCPU-hours). Use \"k\" for thousands without a space (e.g., 55k operations). Use *per* instead of (/) for rates. Ensure clarity in currency and use the correct decimal/binary unit.\n"],null,["# Units of measurement\n\nPut a nonbreaking space between the number and the unit.\n\nSpaces in units of measurement\n------------------------------\n\nFor most units of measurement, when you specify a number with the unit, use a\nnonbreaking space between the number and the unit. This guidance applies in both\nHTML and Markdown.\n\nFor guidance about when to spell out units, see the\n[Abbreviations](/style/abbreviations#spelling-out) page. \nRecommended: `64 GB` (64 GB)\n\nRecommended: `25 mm` (25 mm)\n\nNot recommended: `64 GB`\n\nNot recommended: 64GB\n\nHowever, when the unit of measure is money or percent or degrees of an angle,\ndon't use a space. For more information, see [Currency](#currency). \nRecommended: $10\n\nRecommended: £25\n\nRecommended: 65%\n\nRecommended: 180°\n\nFor degrees of temperature, don't use a space before the degree symbol, but\ndo use a nonbreaking space between the degree symbol and the abbreviation for\nthe temperature scale (*F* or *C* ). For Kelvin temperatures, leave\nout the degree symbol but use a nonbreaking space before the *K*. \nRecommended: `50° C` (50° C)\n\nRecommended: `300 K` (300 K)\n\nWhen a number and unit of measurement combine to modify a noun, don't hyphenate unless\nthe hyphen is needed for clarity.\n\nRecommended:\n`200 GB disk` (200 GB disk)\n\nRanges of numbers with units\n----------------------------\n\nIn a range of numbers, repeat the unit for each number. *Unit* includes both symbols (like\nthe degree symbol (º)) and abbreviations (like *MB* for megabytes) but not nouns\n(like *file* ). For more information, see\n[Range of numbers](/style/hyphens#number-range).\n\nUse the word *to* between the numbers, rather than a hyphen. A hyphen\ncan be misinterpreted as a subtraction sign. \nRecommended: -40° C to 85° C\n\nNot recommended: -40-85° C\n\nHyphens with multiplied units\n-----------------------------\n\nWhen the components of a unit of measurement are multiplied by each other,\nhyphenate them.\n\nRecommended: 5 vCPU-hours\n\nRecommended: 40 person-hours\n\nUse *k* to indicate thousands\n-----------------------------\n\nIn some contexts, it might be appropriate to indicate thousands of something by\nfollowing a number with a lowercase *k*. If you do that, then follow these\nguidelines:\n\n- Don't put a space between the number and *k*.\n- Add a noun to indicate what the number measures, and to make clear that you're not using *k* as an abbreviation for *kilobytes*.\n\nRecommended: On this plan, you are\nlimited to 55k download operations and 20k upload operations per day.\n\nCurrency\n--------\n\nIf you're writing about monetary amounts, make sure that the reader knows what\ncurrency you're referring to. For example, the dollar sign---the *$*\nsymbol---can refer to US dollars, Canadian dollars, Mexican pesos, and several\nother currencies.\n\nIf there's any possibility of ambiguity, use a currency indicator before\nthe amount. For details, see section 9.20 and following in the Chicago Manual of Style, 17th edition.\n\nRecommended: US$10\n\nRates\n-----\n\nUse *per* instead of the division slash (/) when space permits.\nIt's OK to use the division slash when space is limited,\nsuch as in a table with small cells.\n\nShorten *per* to *p* only for well-established abbreviations for\nrate units, such as *Gbps* for *gigabits per second* or\n*MBps* for *megabytes per second*.\n\nRecommended: requests per day\n\nNot recommended: requests/day\n\nRecommended: Gbps\n\nNot recommended: Gb/s\n\nDecimal and binary units\n------------------------\n\nUse the same system to measure bytes as the technology that you're documenting.\nDon't use *MB* if you mean *MiB* , or *GB* if you mean *GiB* . The following\ntable lists common types of\n[decimal and binary units](https://en.wikipedia.org/wiki/Byte#Multiple-byte_units):\n\n| Decimal units | Binary units |\n|---------------------------------|----------------------------------|\n| kB (kilobyte, or 1000 bytes) | KiB (kibibyte, or 1024 bytes) |\n| MB (megabyte, or 1000^2^ bytes) | MiB (mebibyte, or 1024^2^ bytes) |\n| GB (gigabyte, or 1000^3^ bytes) | GiB (gibibyte, or 1024^3^ bytes) |\n\nFor more information about abbreviating measurement terms, see\n[When to spell out a term](/style/abbreviations#spelling-out).\n\nProvide visuals for math concepts\n---------------------------------\n\nAccompany math concepts and numerals with\n[diagrams or other images](/style/images)\nto support comprehension. For example, if comparing statistics, consider illustrating percentages in\na pie chart or a bar graph.\n\nAccompany numerical concepts with real-world practical implications\n-------------------------------------------------------------------\n\nAccompany numerical concepts with real-world practical implications to provide tangible meaning.\nFor example, if using a feature incurs additional fees, add a link to pricing calculator."]]