The Feast

Home cooking recipes for everyday dinners and easy entertaining

How Long to Cook Mac and Cheese Perfect Every Time

· 5 min read · Dinners

Mac and cheese is a beloved comfort dish made from tender pasta bound in a rich, creamy cheese sauce. Getting the timing right ensures perfectly cooked pasta and a sauce that’s smooth, not grainy or separated. This guide breaks down exactly how long to cook mac and cheese—whether baked or stovetop—so you get consistent, delicious results every time.

Ingredients

  • 8 ounces (225g) elbow macaroni or small pasta
  • 3 tablespoons (45g) unsalted butter
  • 3 tablespoons (24g) all-purpose flour
  • 2 cups (480ml) whole milk, warmed
  • 1/2 teaspoon salt, or to taste
  • 1/4 teaspoon black pepper
  • 1/4 teaspoon garlic powder (optional)
  • 1/4 teaspoon paprika (optional)
  • 2 cups (225g) shredded sharp cheddar cheese
  • 1/2 cup (55g) shredded Gruyère or mozzarella (optional, for creaminess)
  • 1/2 cup (50g) grated Parmesan cheese (optional, for topping)
  • 1/2 cup panko breadcrumbs (optional, for topping)

Instructions

  1. Preheat your oven to 375°F (190°C) if making baked mac and cheese. For stovetop-only, skip preheating.
  2. Bring a large pot of salted water to a boil. Add the elbow macaroni and cook for 7–8 minutes, or until al dente (firm to the bite). Do not overcook, as pasta will continue to absorb liquid in the sauce. Drain and set aside.
  3. In a medium saucepan, melt the butter over medium heat. Add the flour and whisk constantly for 1–2 minutes to form a roux. The mixture should be bubbly and golden but not browned.
  4. Gradually pour in the warm milk, whisking continuously to prevent lumps. Cook for 4–5 minutes, until the mixture thickens enough to coat the back of a spoon.
  5. Reduce heat to low. Stir in salt, pepper, garlic powder, and paprika. Add the shredded cheddar and optional Gruyère, a handful at a time, stirring until each addition is fully melted before adding more. Avoid high heat to prevent the sauce from breaking.
  6. Fold the cooked pasta into the cheese sauce until evenly coated. Taste and adjust seasoning if needed.
  7. For stovetop mac and cheese: Serve immediately while hot and creamy.
  8. For baked mac and cheese: Transfer the mixture to a greased 2-quart baking dish. In a small bowl, mix panko breadcrumbs and Parmesan (if using), then sprinkle evenly over the top.
  9. Bake uncovered for 20–25 minutes, until the top is golden and the sauce is bubbling around the edges. Let rest 5–10 minutes before serving for cleaner cuts and safer eating temperature.

Tips

  • Use freshly shredded cheese—pre-shredded contains anti-caking agents that can make the sauce grainy.
  • Warm the milk before adding it to the roux to prevent lumps and speed thickening.
  • Undercook pasta by 1 minute if baking—extra time in the oven will finish cooking it.
  • Don’t boil the cheese sauce—keep heat low when melting cheese to avoid separation.

Serving Suggestions

Serve mac and cheese hot as a standalone dish or alongside grilled chicken, roasted vegetables, or a crisp green salad. It pairs well with a light vinaigrette to cut the richness. For a comforting meal, add crispy bacon bits or sautéed onions on top just before serving.

Variations

  • Spicy Mac: Add 1/4–1/2 teaspoon cayenne pepper or diced jalapeños to the sauce.
  • Loaded Baked Mac: Mix in cooked, crumbled bacon, diced ham, or sautéed mushrooms before baking.
  • Vegetable-Boosted: Stir in steamed broccoli, peas, or roasted cauliflower florets with the pasta.
  • Gluten-Free: Use gluten-free pasta and substitute cornstarch or gluten-free flour for the all-purpose flour in a 1:1 ratio.

Storage and Reheating

Store cooled mac and cheese in an airtight container in the refrigerator for up to 4 days. To reheat, add 1–2 tablespoons of milk per cup to restore creaminess. Warm in the microwave at 50% power in 1-minute intervals, stirring between, until heated through. For oven reheating, cover with foil and bake at 350°F (175°C) for 20–25 minutes. Do not leave cooked mac and cheese at room temperature for more than 2 hours.

Frequently Asked Questions

How long should mac and cheese cook on the stovetop?

Stovetop mac and cheese takes about 20 minutes total, including 8 minutes to cook the pasta and 12 minutes to make the sauce and combine. The dish is ready as soon as the cheese is melted and the pasta is coated. Serve immediately to enjoy the creamiest texture.

How long to bake mac and cheese after it’s already made?

Bake assembled mac and cheese for 20–25 minutes at 375°F (190°C). The dish is done when the top is golden, the edges are bubbling, and the internal temperature reaches 165°F (74°C) if checked with a food thermometer. Let it rest before serving to avoid burns and allow the sauce to set slightly.

Can I make mac and cheese ahead of time?

Yes. Assemble the dish up to 24 hours in advance and refrigerate unbaked. Add 5–10 minutes to the baking time if starting cold. For stovetop, reheat gently with extra milk. Do not freeze unless using a tested freezer-safe recipe, as dairy-based sauces may separate when thawed.

Why is my mac and cheese grainy?

A grainy texture usually comes from overheating the cheese sauce or using pre-shredded cheese with additives. Always melt cheese over low heat and use freshly grated blocks. If the sauce breaks, remove from heat and whisk in a spoonful of lemon juice or cold milk to bring it back together.

Can I use low-fat milk or cheese?

You can, but the sauce may be thinner and less creamy. Whole milk and full-fat cheese provide the best texture and flavor. If using lower-fat dairy, consider adding a bit more roux (butter and flour) to help thicken the sauce.

How do I keep baked mac and cheese from drying out?

Avoid overbaking and undercooking the pasta initially. Use enough sauce to generously coat the pasta—about 2 cups of liquid per 8 oz pasta. Cover with foil during the first 15 minutes of baking if the top browns too quickly, then uncover to crisp the top.

In this article
  1. Ingredients
  2. Instructions
  3. Tips
  4. Serving Suggestions
  5. Variations
  6. Storage and Reheating
  7. Frequently Asked Questions