JSON strings are stricter than JavaScript strings, and stricter than most people expect. A raw newline inside quotes is a syntax error. So is a raw tab. So is a backslash in front of a letter the spec never defined, which is exactly what a Windows path looks like.
Everything else is legal. Chinese text, emoji, curly quotes, accented characters: all fine in UTF-8, no escaping required.
The complete set
There are eight defined escapes: \", \\, \/, \b, \f, \n, \r, \t, plus \uXXXX for any code point. \/ is legal and never necessary. \x41 is not legal. Nor is \0, nor \'.
That is it. If a backslash is followed by anything outside this set, the parser rejects the document, usually with a column number that points somewhere unhelpful.
Mistake one: a literal newline
{"note": "line one
line two"}
Invalid, and the error message will complain about a control character rather than a missing quote, which sends people looking in the wrong place. A newline in a JSON string is \n. The parser turns it back into a real newline character on read.
Mistake two: single quotes
{'name': 'value'}
Invalid. JSON requires double quotes for keys and strings. Single quotes work in JavaScript object literals, Python dicts and YAML, which is why they keep getting pasted into JSON.
Mistake three: Windows paths
{"path": "C:\temp\new"}
The parser reads \t as a tab and \n as a newline. The document is valid, the value is wrong, and nothing reports a problem. Double every separator (C:\\temp\\new) or use forward slashes, which JSON treats as ordinary characters.
This is the one mistake I would fix first in any codebase, because it produces silent data corruption rather than an error.
Mistake four: trailing commas and comments
{"a": 1,}
Invalid. So is anything after // or between /* */. JSON5, JSONC and some config parsers accept both. Strict parsers do not, and a config file that works in one tool will fail in the next.
Mistake five: escaping twice
If a value already contains the two characters backslash and n, and you escape it again, you get \\n. Parse that and you get the literal text \n back, not a newline. The bug shows up when data is serialised into a field and then the field is serialised into an envelope.
Escape once, where the value crosses from a typed object into text.
Unicode and emoji
Raw UTF-8 is legal. {"city":"芜湖"} parses fine. Encoders escape non-ASCII only when they must produce pure ASCII, for example inside an HTTP header.
\uXXXX covers the Basic Multilingual Plane in four hex digits. Characters above U+FFFF, including most emoji, are either written raw or as a surrogate pair, \uD83D\uDE00 for a grinning face. A lone surrogate is accepted by some parsers and rejected by others, so a producer that escapes emoji had better escape both halves.
Per language, briefly
JavaScript: JSON.stringify escapes quotes, backslashes and control characters and leaves non-ASCII alone. Build objects and serialise them. Do not concatenate strings to produce JSON, because one unescaped quote produces a document that fails at the consumer, not at the writer.
PowerShell: ConvertTo-Json escapes correctly but defaults to a depth of 2, silently turning deeper objects into their string representation. Pass -Depth and read the output before sending it.
SQL: MySQL has JSON_QUOTE, PostgreSQL has to_json. String concatenation does not escape the value's own quotes and backslashes, no matter how carefully you wrap it.
Python: json.dumps(value, ensure_ascii=False) keeps CJK readable. The default escapes them, which is fine for transport and annoying for files people read.
Inlining JSON into HTML
A </script> sequence inside a quoted JSON string still ends the surrounding script block. The HTML tokenizer does not care about JavaScript quoting. Escape the angle bracket before embedding:
JSON.stringify(data).replace(/</g, "\\u003c")
The parser decodes \u003c back to <, and the tokenizer never sees a tag.
How to check a document
Format it first; a syntax error appears immediately with a position. Then validate. Then parse, re-serialise and compare the objects rather than the strings, since key order and escape style may differ legitimately.
For a single value that has to go into an existing document, escape just that value with the JSON escape tool. For whole files, the JSON formatter will find the error faster than reading the source, and the JSON validator confirms the document parses.