Reference1 min

JSON Syntax Reference

Complete JSON syntax reference

JSON Syntax Reference

A concise JSON syntax guide.


📝 Basic Syntax

Objects

{
  "key": "value",
  "name": "YAMLforge",
  "port": 8080
}

Nesting

{
  "parent": {
    "child": "value",
    "nested": {
      "deep": "data"
    }
  }
}

📊 Data Types

TypeExample
String"hello"
Number42
Float19.99
Booleantrue / false
nullnull
Array[1, 2, 3]
Object{"key": "value"}

📋 Arrays

{
  "items": [
    "item1",
    "item2",
    "item3"
  ],
  "numbers": [1, 2, 3],
  "mixed": [1, "two", true, null]
}

⚠️ Important Notes

  • No comments: JSON doesn't support comments
  • No trailing commas: Can't have comma after last element
  • Double quotes only: Strings must use double quotes
Tags
#json#syntax#reference#documentation