How do PostgreSQL JSON and JSONB differ?
JSON
JSONB
JSONB stores only plain strings and cannot represent arrays or objects.
They are aliases with identical storage and query behavior.
Only JSON supports efficient indexing; JSONB cannot be indexed.
JSON preserves an exact copy of the input text, while JSONB stores decomposed binary data suited to querying and indexing.