Quick answer
JSON Line Ending – causes and fixes.
JSON Line Ending
JSON Line Ending – causes and fixes. Use a JSON validator to locate the error.
Common causes
- Mixed CRLF/LF.
- Raw newline in string.
How to fix
- Normalize; use \n in strings.
Use our JSON Validator to paste your input and see the exact error location. Validatethis.org offers free validators for JSON, XML, CSV, HTML, and more. Check /tools for the full list. For API access and integration, see /developers.
FAQ
- Line endings?
- Between tokens ok.
- In string?
- \n only.
Fix it now
Try in validator (prefill this example)