# Parse Error json object

**URL:** <https://discuss.elastic.co/t/parse-error-json-object/264534>\
**Category:** Logstash\
**Created:** [February 17, 2021, 8:33am UTC](https://discuss.elastic.co/t/parse-error-json-object/264534 "2021-02-17T08:33:16Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ljeganathan](https://avatars.discourse-cdn.com/v4/letter/l/54ee81/32.png) [@ljeganathan](https://discuss.elastic.co/u/ljeganathan)\
**Post date:** [February 17, 2021, 8:33am UTC](https://discuss.elastic.co/t/parse-error-json-object/264534/1 "2021-02-17T08:33:16Z")

</div>

Hi,  
I am getting parse error like below

JSON parse error, original data now in message field {:error=\>#\<LogStash::Json::ParserError: Unexpected character ('\' (code 92)): was expecting double-quote to start field name

## Original Json

"{\"level\":\"info\",\"client\_code\":\"xxx\",\"xxx\":\"xxx\",\"timestamp\":\"2020-10-15 16:17:25\",\"entity\_type\":\"xxx\",\"entity\":\"xxx\",\"efid\":\"xxx\",\"pqid\":\"xxx\",\"count\":3000}"

Could you please provide solution

Regards,  
Senthil. L

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [February 17, 2021, 5:05pm UTC](https://discuss.elastic.co/t/parse-error-json-object/264534/2 "2021-02-17T17:05:47Z")

</div>

The double quotes in your source are escaped. You need to remove the escapes. A simplistic solution would be

```
mutate { gsub => ["message", '\\"', '"'] }

```

If there are quoted strings within the JSON then you would need a more sophisticated solution to parse it.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [March 17, 2021, 5:06pm UTC](https://discuss.elastic.co/t/parse-error-json-object/264534/3 "2021-03-17T17:06:32Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
