What the error means
In JSON, every key must be a string in double quotes. When the parser reaches the position where a key should start and sees anything else, such as a single quote, a bare word or a closing brace after a comma, it raises this error and reports the line, column and char offset. For '{'a': 1}' the position is char 1, the opening single quote.
The editor above opens on a Python-style dictionary. Click Validate and it stops at the first single quote, the same spot Python reports.
Causes and fixes
Look at the character at the reported position and match it to one of these.
Single-quoted keys: a Python dict printed as text
Error: Expecting property name enclosed in double quotes: line 1 column 2 (char 1)
Invalid
{'name': 'Ada', 'admin': True, 'manager': None}Fixed
{"name": "Ada", "admin": true, "manager": null}str(d) and print(d) give Python syntax: single quotes, True, False and None. Create JSON with json.dumps(d). If you were handed Python-syntax text and cannot change the source, ast.literal_eval(text) reads it safely, and json.dumps turns the result into JSON.
Unquoted key
Error: Expecting property name enclosed in double quotes: line 1 column 2 (char 1)
Invalid
{name: "Ada"}Fixed
{"name": "Ada"}JavaScript allows bare keys in object literals; JSON does not. Put every key in double quotes.
Trailing comma in an object (Python before 3.13)
Error: Expecting property name enclosed in double quotes: line 1 column 9 (char 8) (Python 3.13: Illegal trailing comma before end of object)
Invalid
{"a": 1,}Fixed
{"a": 1}After a comma the parser expects another key, and finds the closing brace. Remove the last comma. Python 3.13 names the problem directly.
JSON written by hand or copied from a JavaScript file
Error: Expecting property name enclosed in double quotes
Invalid
{
// settings
"debug": true
}Fixed
{
"debug": true
}Comments are not JSON either. Config files that allow them (VS Code settings, tsconfig.json) use a looser format called JSONC that Python's json module does not read.