# How to store data in JSON file in Node-RED

**URL:** https://discourse.nodered.org/t/how-to-store-data-in-json-file-in-node-red/6480
**Category:** General
**Created:** [6 January 2019 23:56 UTC](https://discourse.nodered.org/t/how-to-store-data-in-json-file-in-node-red/6480 "2019-01-06T23:56:57Z")
**Posts on this page:** 1
**Showing post:** 17

<div class="post-metadata">

### Author: ![drmibell](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/drmibell/32/8424_2.png) [@drmibell](https://discourse.nodered.org/u/drmibell)
#### Post date: [11 January 2019 16:34 UTC](https://discourse.nodered.org/t/how-to-store-data-in-json-file-in-node-red/6480/17 "2019-01-11T16:34:56Z")

</div>

Maybe I'm missing something. I would expect `Object.keys(myObj).length` to give the number of keys in `myObj`. So I'm not sure how this solves the problem(s) here.

---

_[View the full topic](https://discourse.nodered.org/t/how-to-store-data-in-json-file-in-node-red/6480)._
