No-Break Space (U+00A0)

No-Break Space is a normal-width space that keeps the words on each side together on one line.

Updated By Milind Sahu How we test

Copy tool
U+00A0, 2 bytes

U+00A0Zs · spacehas width

Need the code?HTML, CSS, JS escapesFind it in text

How we test

An app result is shown only after a hand test on a named app version, with the date. Results older than 120 days are hidden until re-tested.

Read the method →

What is the No-Break Space used for?

The No-Break Space (U+00A0) is used to keep two words on the same line, such as a number and its unit in 10 km. It is meant to be as wide as a normal space, but no line break happens on either side of it. In HTML it is written as the   entity.

Commonly abbreviated NBSP, it is in the Latin-1 Supplement block and dates from Unicode 1.1. The names list says it should be the same width as the regular space, U+0020.

Its line break class is GL, for glue, so no line break happens on either side. Use it between a number and its unit, as in 10 km, so the pair never splits across lines.

It is category Zs and has the White_Space property. So trim() and the \s pattern treat it as a space, and NFKC normalization turns it into a plain U+0020.

In HTML it is the   entity. Browsers collapse runs of normal spaces into one but keep each no-break space, which is why it gets used for extra spacing on web pages.

Watch out for

  • It counts as whitespace, so apps that trim spaces can remove it from a blank name.
  • Pasted from a web page, it can break exact matches, because it is not the same character as a normal space.
  • In UTF-8 it takes 2 bytes (C2 A0).

Sources: Unicode names list (NamesList.txt) · Unicode line breaking (UAX #14) · Computed from the character itself (see Codes and escapes) · Unicode blocks (Blocks.txt) · Unicode version each character arrived (DerivedAge.txt) · Unicode character data (UnicodeData.txt) · Unicode properties (PropList.txt) · ECMAScript: white space · Unicode normalization (UAX #15) · CSS Text: white space processing

Codes and escapes

FormatValueCopy
HTML entity   ·  
CSS \A0
JavaScript / Java \u00A0
Python \u00A0
URL-encoded %C2%A0
UTF-8 bytes C2 A0

Properties

Unicode category
Zs (Space separator)
Treated as whitespace
Yes
Width
Takes up space
Unicode name
NO-BREAK SPACE

Where it works

Not tested yet. Results appear here with the app version and date once each app is tested by hand.

Similar characters

Back to all 13 invisible characters

FAQ

How do I type a no-break space?

To type a no-break space, copy it from the tool above, or write   in HTML and \u00A0 in JavaScript. In UTF-8 it takes 2 bytes, C2 A0. Put it between words that must stay on the same line, such as a number and its unit, so they never split.

Why doesn't Excel's TRIM remove no-break spaces?

Excel's TRIM doesn't remove no-break spaces because, as Microsoft's documentation says, it only trims the ASCII space, character 32. The no-break space is character 160, so it stays. Replace it with a normal space first, or paste the text into the detector to find every one.

Can I use a no-break space for a blank name?

A no-break space is a poor choice for a blank name, because Unicode classes it as whitespace. Apps that trim spaces from a name field can remove it, and NFKC normalization turns it into a plain space. A letter-class blank such as the Hangul Filler survives that trimming.