IE 11 is not supported. For an optimal experience visit our site on another browser.

Gruyere Mac and Cheese with Caramelized Onions

Molly Yeh's Mac & cheese, 2 ways: Smoky bacon + Gruyere with caramelized onions --february 22, 2017.
Molly Yeh's Mac & cheese, 2 ways: Smoky bacon + Gruyere with caramelized onions --february 22, 2017.Nathan Congleton / TODAY

Chef notes

One of the only things that can make a perfect thing better is dumping in a bunch of caramelized onions. So I did just that with a version of my mom's mac and cheese, and then added some mustard for a tiny zing. It makes the house smell amazing and makes for a fancier version of my favorite comfort food. 

Technique Tip: You can use this sauce as a base and then add pretty much any cheese you'd like to tailor this recipe to your tastes or whatever cheese you have on hand. Also, in a pinch, you can skip the baking step. Simply cook the pasta fully before stirring it in with the cheese sauce, then serve immediately topped with panko and Parmesan. Alternatively, you can prepare this ahead and keep it in a baking dish in the fridge or freezer until you're ready to bake.

Swap Option: You can swap out the Gruyere for any other cheese, also other types of milk would work as well, as would gluten free all-purpose flour and gluten free pasta.


  • 6 tablespoons (3 ounces) unsalted butter
  • 1 large onion, thinly sliced
  • Kosher salt
  • 8 ounces medium shells
  • 1/4 cup flour
  • 3 cups whole milk
  • 6 ounces Gruyère cheese, shredded
  • 2 ounces Parmesan cheese, grated
  • 1 teaspoon sweet paprika
  • 1/4 cayenne pepper
  • 1/4 teaspoon ground nutmeg
  • 2 teaspoons Dijon mustard
  • Black pepper
  • 1/2 cup panko breadcrumbs



Preheat the oven to 375°F. Grease an 8 x 8-inch baking dish.


In a large skillet, melt 2 tablespoons of the butter over medium heat. Add the onion and a pinch of salt and cook, stirring occasionally, until browned and caramelized.


Cook the pasta according to the package directions, reducing the cooking time by 1 minute. Drain and set aside.


In a large pot, melt the remaining 4 tablespoons butter over medium-high heat. Add the flour, whisking until combined, and then cook for 1 minute. Add half the milk, whisking continuously until thickened, about 5 minutes and then repeat with the other half of the milk. Add the Gruyère, swiss, and all but 2 tablespoons of the Parmesan and stir until the cheese melts. Stir in the paprika, cayenne, nutmeg, mustard, and black pepper and salt to taste. Stir in the pasta and onions.


Transfer the mixture to the baking dish and top with the panko and the reserved Parmesan and bake until the top is browned, about 25 minutes. Cool for 5 minutes and enjoy.