The closet itself generally does not have a minimum size requirement just to be included in the home's square footage. What matters is whether the room containing the closet qualifies as living area under the applicable measurement/appraisal rules. A closet also does not necessarily need doors; an open closet with shelves or a rod can still function as a closet. It doesn't have to be factory-built or professionally installed either. However, if you're asking specifically whether a room can be counted as a bedroom, that's different: California appraisers and local building requirements can look at things like minimum room dimensions, ceiling height, emergency egress, heating, and access, and a closet is generally not the sole requirement for bedroom classification.


