Reference

null

When a schema specifies a type of null, it has only one acceptable value: null.

It's important to remember that in JSON, null isn't equivalent to something being absent. See Required Properties for an example.

Language-specific info:
Python
Ruby
Objective-C
Swift
In Python, null is analogous to None.
schema
{ "type": "null" }
Copy
data
null
Copy
compliant to schema
data
false
Copy
not compliant to schema
data
0
Copy
not compliant to schema
data
""
Copy
not compliant to schema
data
Copy
not compliant to schema

Need help?

Learning JSON Schema is often confusing, but don't worry, we are here to help! You can start a thread on GitHub Discussions, connect with us on Slack, or join our live Office Hours.
We'd love to help!! ❤️