> For the complete documentation index, see [llms.txt](https://help.stockeo.solvenium.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.stockeo.solvenium.com/troubleshooting/unexpected-token-in-json-at-position-0.md).

# Unexpected token \* in JSON at position 0

This error occurs when the feed format is set to JSON in the Data Mapping section, but the feed does not contain valid JSON.

This error means that Stockeo is trying to process the feed as JSON, but the feed does not start with valid JSON data.

The `*` represents the character found at the beginning of the feed. It can be any character other than `{` or `[`, which are valid starting characters for a JSON document.

<figure><img src="https://2071801931-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fz6HyRe5TyFXHKQEybH7n%2Fuploads%2FdhIEEl6PrzJsLVuzlist%2Funexpected-token-in-json-error.png?alt=media&amp;token=da182fb0-047e-4cab-9ea0-9da41527a9fc" alt="Unexpected token in JSON error message"><figcaption><p>Example of the JSON parsing error in Stockeo</p></figcaption></figure>

#### How to fix it

Check the following:

1. **Check the feed format**

   Make sure **JSON** is selected in the **Data Mapping** section only if the feed actually contains JSON data. If the feed uses another format, select the appropriate format instead.
2. **Check the feed response**

   If the feed is retrieved through an API, the API may return an error page instead of JSON. For example, an HTML error page starts with:<br>

   ```
   <!doctype html>
   ```

   \
   In this case, Stockeo may return:<br>

   ```
   Unexpected token < in JSON at position 0
   ```

   \
   Check the API response and make sure that it returns valid JSON. If it returns an error page, contact the API provider to resolve the issue.
