The North American Industry Classification System is used to organize industry information. It is a hierarchical classification system, offering five levels of detail.
Industries are represented by a six-digit number. The first two digits designate the economic sector: manufacturing, agriculture, wholesale, retail, professional services, etc. The subsequent digits designate subsectors and industry groups.
Each digit in the code is part of a series of progressively narrower categories.
Example:
44 - Retail
445 - Food & Beverage Stores
4452 - Specialty Food Stores
445291 - Baked Goods Stores
Thus the NAICS code for bakeries is 445291