DevKits

ASCII 159

Character 159 (Ÿ)

Latin-1 Supplement

Unassigned in Latin-1 / part of the C1 control block. Not used in modern text encoding; browsers accept these code points but they carry no display glyph.

Common uses & context

Decimal 159 (0x9F) falls in the C1 control range (128–159). In the Latin-1 (ISO-8859-1) encoding these code points are unassigned control positions with no visible glyph, and in Windows-1252 many of them were repurposed for typographic characters like curly quotes and the em dash. That mismatch is a classic cause of mojibake: a byte stored as Windows-1252 but decoded as Latin-1 (or UTF-8) shows the wrong character or a replacement box.

In modern Unicode, U+009F is a C1 control code. Its UTF-8 encoding is the two-byte sequence 0xC2 0x9F, which is why a raw high byte 0x9F from a legacy Latin-1 file becomes garbled when a program assumes UTF-8.

All encodings at a glance

Decimal159
Hexadecimal0x9F
Octal0237
Binary10011111
HTML numeric entityŸ
URL encoding%9F
UTF-8 bytes0xC2 0x9F

Code snippets

JavaScript

String.fromCharCode(159); // "Ÿ"
159.toString(16); // "9f"

Python

chr(159)           # control char Ÿ
ord(chr(159))      # 159
hex(159)           # '0x9f'

HTML

&#159;   <!-- numeric entity (no named entity for this character) -->

Programming notes

  • Code 159 is in the C1 control range — unassigned in Latin-1, repurposed in Windows-1252.
  • A raw byte 0x9F decoded as UTF-8 becomes garbage; specify the correct charset explicitly.
  • UTF-8 encoding: 0xC2 0x9F; Unicode code point U+009F.

Unicode & UTF-8 note

In Unicode this is U+009F. In UTF-8 it encodes to the byte sequence 0xC2 0x9F. In legacy Latin-1 (ISO-8859-1) it is a single byte 0x9F, which is why Latin-1 files often appear as mojibake when interpreted as UTF-8.

Frequently asked questions

What character is ASCII code 159?

ASCII code 159 is the character 'Ÿ' (Character 159). In hexadecimal it is 0x9F, in octal 0237, and in binary 10011111.

What is 0x9F in ASCII?

Hexadecimal 0x9F equals decimal 159, which is the character 'Ÿ' (Character 159). To convert hex to ASCII yourself, read the two hex digits as a base-16 number (0x9F = 159) and look up that code point.

How do I write the character with code 159 in code?

In JavaScript use String.fromCharCode(159); in Python use chr(159); in HTML use the numeric entity &#159;. In a URL it is percent-encoded as %9F, and in UTF-8 it is stored as the byte sequence 0xC2 0x9F.

Nearby codes

Encode & convert this character