# json.size · Rell standard library · Chromia Docs (concept)

> pure function size(): integer Get the size of this JSON value; i.e. the number of elements in this JSON array, or the number of
key-value pairs in this JSO

Source: https://docs.chromia.com/pages/rell-stdlib/-rell-system-library/root/json/size/

FUNCTION

# json.size

```signature
pure function size(): integer
```

Get the size of this JSON value; i.e. the number of elements in this JSON array, or the number of
key-value pairs in this JSON object.

**Returns**

the size of this JSON value

**Throws**

* `exception` — if this JSON value is not an array or an object

Since 0.14.16

[View this page on docs.chromia.com](https://docs.chromia.com/pages/rell-stdlib/-rell%20-system%20-library/%5Broot%5D/json/size.html)Generated API reference, mirrored from the live docs
