Questions
Asked often, answered plainly.
( 02 )
What does escaping actually do?
Escaping converts characters that have special meaning in a given context into a safe representation, so they're treated as literal data instead of syntax. A quote inside a quoted string, an angle bracket inside markup, an ampersand inside XML — each would otherwise be misread as structure. Escaping makes them inert, and unescaping turns them back into what they were.
Why isn't SQL escaping enough to prevent SQL injection?
It isn't, and it's important to say so plainly. Manually escaping quotes is fragile: character-set tricks, second-order injection and database-specific escape rules can all defeat it. The real defense is parameterized queries (prepared statements), where the driver separates code from data for you. This tool is for understanding escaping, building literals and reading escaped SQL — not a security boundary.
What's the difference between text escaping and XML escaping?
They serve different contexts with different syntaxes. Text escaping is backslash-based, for string literals in code and data formats: a newline becomes \n, a quote becomes \", a backslash becomes \\. XML escaping is entity-based, for markup: < becomes <, & becomes &. Escaping a string for JSON and pasting it into XML would be wrong — pick the tool that matches where the text will actually be parsed.
Can I round-trip — escape and then unescape?
Yes, every tool here is lossless and bidirectional. Escape something, hit the Feed back button, and the output becomes the input with the direction flipped — unescape it and you're back to exactly what you started with, character for character. It's the fastest way to verify that a round-trip is clean.
Is my data saved anywhere?
No. Stack has no backend and no database. Escaping happens inside your browser tab and the text vanishes the moment you close or refresh the page. Nothing is logged, because nothing is ever collected.