Free foreverNo sign-upRuns 100% in your browser

Escape Sequence Encoder

Encode real newlines and tabs into \n \t escapes for code/JSON strings — or decode escaped text back.

Escape forms

Encode turns newline/tab/CR/backslash/quote into \n \t \r \\ \" — other control chars use \xNN. Optionally non-ASCII uses \uXXXX (or \u{…} above BMP). Decode reverses all of these.

Frequently asked questions

JSON safe?

The escaped output drops straight into a JSON string.

Emoji?

Escaped as \u{1F600} when non-ASCII mode is on.

Partial decode?

Only real escape sequences change — \q stays literal.