Advertisement

Escape or unescape strings for JSON, JavaScript, HTML, URL, SQL, regex or backslash — twin panes, instant, in your browser. Free.

Everything runs in your browser — nothing is uploaded.

Target
Input
Output
</> Result appears here…

About String Escape & Unescape

String Escape & Unescape converts text to and from the escaped form required by seven targets: JSON strings, JavaScript strings, HTML, URLs, SQL, regular expressions and plain backslash escaping. Twin panes update instantly, and a swap button feeds the output back as input for multi-layer jobs.

Each target follows its own rules — JSON escapes quotes and control characters as \n or \u sequences, HTML converts <, > and & to entities, URL encoding percent-escapes reserved characters, SQL doubles single quotes, and regex escaping neutralizes metacharacters like . and * so user input can be matched literally.

It is the quick fix for embedding text in code, building query strings, or reversing an over-escaped log line. Everything runs in your browser with nothing uploaded, so pasted secrets and production log fragments stay private. Free to use, no account needed.

How to use String Escape & Unescape

  1. Choose the direction: Escape or Unescape.
  2. Pick the target format: JSON string, JS string, HTML, URL, SQL, Regex or Backslash.
  3. Paste your text into the input pane, or load the sample.
  4. Read the converted result, using "Use as input" to unwrap or add another escaping layer.
  5. Copy the output to your clipboard.

Frequently asked questions

It backslash-escapes metacharacters such as ., *, +, ? and parentheses so the text matches literally inside a regular expression — essential when interpolating user input into a pattern.

Yes. Run Unescape once per layer, using the swap button to feed each result back in — two passes turn \\n back into a real newline.

No. Escaping quotes helps with literals, but parameterized queries or prepared statements are the correct defense. Use this tool for debugging and one-off strings, not as an injection safeguard.

No. All escaping and unescaping runs in your browser, so log excerpts and credentials you paste are never transmitted.

Yes — free with no usage limits.


Popular searches
string escape string unescape escape json string escape javascript string escape sql string escape regex characters
Need help?
Found an issue with this tool? Let our team know.
Report an issue

Add this free tool to your own website — copy and paste the code below.