2-180%
TextEncoder & TextDecoder
BaselineWidely available
This feature is well established and works across many devices and browser versions. It’s been available across browsers since July 2022.
TextEncoder encodes a JavaScript string into bytes using the UTF-8 encoding and returns the resulting Uint8Array of those bytes. TextDecoder does the reverse.
IE
Edge
Firefox
Chrome
Safari
Safari iOS
Opera Mini
Chrome Android
Android Browser
Samsung Internet
✓Supported
✗Not supported
Partial support