Swiss cheese has holes because of carbon dioxide bubbles that form in the cheese. That’s the short answer.
But if you really want to know more about the science behind the Swiss, we have you covered.
First, you need to get the lingo right. Cheesemakers don’t call those telltale openings “holes;” they call them “eyes.” Eyes are specific to Swiss and they’re caused by a special bacterial culture called Propionibacteria, or Props, that gets added to the cheese.
Props are found in hay, grasses and soil and find their way into raw milk naturally when cows are milked. The pasteurization process kills the bacteria in milk, including Props, so if pasteurized milk is used as the base for Swiss, cheesemakers add some back in so eyes will form.
After the Swiss is made and brined, the blocks or wheels are placed in warm rooms, which helps the Props produce carbon dioxide and also keeps the cheese at the right consistency.
Plus -- props to the Props! -- the handy bacteria also help give Swiss its characteristic nutty flavor. And they play the lead role in a number of other cheeses related to Swiss.
For example, while we call it “Swiss” cheese in the U.S., Swiss cheese made in Switzerland is called Emmental. Other varieties, such as Baby Swiss and Jarlsburg, are types of Emmental, with different amounts of moisture, fat and other bacterial cultures that may have been added along with the Props.
Source - usdairy.com