The typeof null returns 'object', which is considered a historical bug in JavaScript. Although null is a primitive value, typeof null returns 'object' because in the first JavaScript implementations, JavaScript values were represented as a type tag and a value. The type tag for objects was 0, and null was represented as the NULL pointer (0x00 in most platforms). As a result, null had 0 as a type tag, hence the 'object' typeof return value.