Mathias Bynens personal blog

JavaScript’s internal character encoding: UCS-2 or UTF-16?

Does JavaScript use UCS-2 or UTF-16 encoding? Since I couldn’t find a definitive answer to this question anywhere, I decided to look into it. The answer depends on what you’re referring to: the JavaScript engine, or JavaScript at the language level.
Points
0
HN comments
0
Submissions
0
Cited by
11 commenters

Web & FrontendSoftware Engineering2012

Cited in comments

Linked from 13 Hacker News comments by 11 different people, from Feb 2012 to Aug 2025.

Most recent:

Search every comment that links here →

More from Mathias Bynens

All 6 posts →

Related posts from the same era