---
title: "What are the data types supported by JSON, and how are they represented in JSON objects?"  
description: "What are the data types supported by JSON, and how are they represented in JSON objects?"  
author: "Utpal Vishwas"  
published: 2023-10-10  
updated: 2023-10-11  
canonical: https://www.mindstick.com/forum/160089/what-are-the-data-types-supported-by-json-and-how-are-they-represented-in-json-objects  
category: "json"  
tags: ["javascript", "json", "jsonobject"]  
reading_time: 2 minutes  

---

# What are the data types supported by JSON, and how are they represented in JSON objects?

What are the [data types supported](https://www.mindstick.com/forum/158383/what-are-the-data-types-supported-by-sqlite) by [JSON](https://www.mindstick.com/forum/34446/convert-json-string-to-object), and how are they represented in JSON [objects](https://www.mindstick.com/forum/145447/what-are-objects)?

## Replies

### Reply by Aryan Kumar

JSON (JavaScript Object Notation) supports several [data](https://www.mindstick.com/articles/13050/salesforce-aiming-to-dominate-predictive-analytics-with-data-science) types for representing structured data. These data types are represented in JSON objects using specific syntax. Here are the common data types supported by JSON and their representations in JSON objects:

**String**:

- **JSON Representation**: Strings are enclosed in double quotation marks.
- **Example**: **"Hello, World"**

**Number**:

- **JSON Representation**: Numbers can be integers or floating-point values.
- **Example**: **42** or **3.14**

**Boolean**:

- **JSON Representation**: Boolean values are represented as **true** or **false**.
- **Example**: **true**

**Object**:

- **JSON Representation**: Objects are enclosed in curly braces **{}** and contain key-value pairs. Keys are strings, and values can be any JSON data type, including nested objects and arrays.
- **Example**:

```plaintext
{
  "name": "John",
  "age": 30
}
```

**Array**:

- **JSON Representation**: Arrays are enclosed in square brackets **[]** and contain an ordered list of values. Values can be of any JSON data type, including objects and nested arrays.
- **Example**:

```plaintext
["apple", "banana", "cherry"]
```

**Null**:

- **JSON Representation**: The null value is represented as **null**.
- **Example**: **null**

**Nested Data Types**: JSON supports nesting data types within objects and arrays. For example, you can have objects within objects, arrays within objects, arrays of objects, and so on, to represent complex data structures.

**Nested Object Example**:

```plaintext
{
  "person": {
    "name": "Alice",
    "age": 25
  }
}
Nested Array Example:
{
  "fruits": ["apple", "banana", "cherry"]
}
```

**Special Values**: JSON does not have specific data types for date, time, or binary data. These types of data are typically represented as strings in JSON and require application-specific handling for interpretation.

JSON is a versatile data format used for data exchange, configuration, and storage, and it can represent a wide range of data types, making it suitable for various use cases in web development and data communication.


---

Original Source: https://www.mindstick.com/forum/160089/what-are-the-data-types-supported-by-json-and-how-are-they-represented-in-json-objects

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
