JS String Escape Online

Escape and unescape JavaScript strings.

About JS String Escape

Escape special characters in JavaScript strings. This tool converts characters like newlines, tabs, quotes, and backslashes into their escaped equivalents so you can safely embed strings in your code.

Supports escaping of \\n, \\r, \\t, \\\\, \\", \\', and \\uXXXX unicode sequences.