None Null constant
Last updated: 2026-09-22
None Null constant
None is the sole instance of NoneType; commonly used to denote 'no value' (distinct from False).
| Category | Keywords & Statements |
|---|---|
| Kind | Keyword / Statement |
| Python Version | all |
📝 Syntax
None
▶ Example
Edit the code, press Run, and see the result in the output panel:
Output:
None
True
False
ℹ️ Info Check None with `is None`, not `==`.
💡 Related Cases
More case studies coming soon — check back later.
❓ FAQ
QShould I check for `None` with `==` or `is`?
AUse `is None` or `is not None`. The `==` operator can be overloaded by a custom `__eq__` and give wrong results, whereas `is` compares object identity and is always correct for the singleton `None`.
QWhat is the difference between `None` and `False`?
A`None` means «no value» and is the only instance of `NoneType`. `False` is a boolean falsy value. `None == False` evaluates to `False` — they are completely different objects.
QWhat does a function return when it has no `return`?
AIt returns `None`. That is why `if f() is None` is a common way to test whether a function returned an explicit value; note that the test should use `is`, not `==`.