Quick Recipe Version (TL;DR)
Quick Ingredients
- 3 lb Yukon Gold potatoes, peeled (optional) and sliced 1/8-inch thick
- 1 medium yellow onion, thinly sliced
- 1 1/2 lb cooked ham, diced (about 3 cups)
- 4 tbsp unsalted butter
- 1/4 cup all-purpose flour
- 2 1/2 cups whole milk
- 1 cup heavy cream
- 2 cloves garlic, minced
- 1 tbsp Dijon mustard
- 1 1/2 tsp kosher salt
- 1/2 tsp black pepper
- 1 tsp dried thyme
- 1/8 tsp ground nutmeg (optional)
- 2 cups shredded sharp cheddar cheese (8 oz)
- 1 cup shredded Gruyère cheese (4 oz)
- 1 tbsp chopped parsley (optional, for serving)
Do This
- 1. Heat oven to 350°F. Butter a 9×13-inch baking dish.
- 2. Slice potatoes 1/8-inch thick; slice onion; dice ham.
- 3. Make sauce: melt butter, whisk in flour 1 minute; whisk in milk + cream; simmer until thick; stir in garlic, Dijon, seasonings.
- 4. Layer half the potatoes, half the onion, half the ham, and one-third of the sauce; repeat; pour remaining sauce over top.
- 5. Cover tightly with foil and bake 1 hour 15 minutes.
- 6. Uncover and bake 20 minutes more. Top with cheeses and bake 10 minutes until bubbling and browned at the edges.
- 7. Rest 20 minutes before slicing and serving.
Why You’ll Love This Recipe
- Comforting and hearty: creamy potatoes plus savory ham makes it a true main dish.
- Sliceable (not soupy): a thick, well-seasoned sauce and a proper rest time help it set up.
- Great for feeding a crowd: one pan serves 8 and reheats beautifully.
- Make-ahead friendly: assemble ahead, bake when you’re ready.
Grocery List
- Produce: Yukon Gold potatoes, yellow onion, garlic, parsley (optional)
- Dairy: unsalted butter, whole milk, heavy cream, sharp cheddar cheese, Gruyère cheese
- Pantry: all-purpose flour, Dijon mustard, kosher salt, black pepper, dried thyme, ground nutmeg (optional)
Full Ingredients
Potatoes, Ham, and Aromatics
- 3 lb Yukon Gold potatoes, peeled (optional) and sliced 1/8-inch thick (about 10–12 cups sliced)
- 1 medium yellow onion, thinly sliced (about 1 1/2 cups)
- 1 1/2 lb cooked ham, diced (about 3 cups)
- 1 tbsp unsalted butter (for greasing the baking dish)
Creamy Sauce
- 4 tbsp unsalted butter
- 1/4 cup all-purpose flour
- 2 1/2 cups whole milk
- 1 cup heavy cream
- 2 cloves garlic, minced
- 1 tbsp Dijon mustard
- 1 1/2 tsp kosher salt
- 1/2 tsp freshly ground black pepper
- 1 tsp dried thyme
- 1/8 tsp ground nutmeg (optional, but excellent)
Cheesy Finish
- 2 cups shredded sharp cheddar cheese (8 oz), preferably freshly shredded
- 1 cup shredded Gruyère cheese (4 oz), preferably freshly shredded
- 1 tbsp chopped parsley (optional, for serving)

Step-by-Step Instructions
Step 1: Prep the pan and heat the oven
Arrange a rack in the center of the oven and preheat to 350°F. Grease a 9×13-inch baking dish with 1 tbsp butter. This helps prevent sticking and makes it easier to lift and slice clean portions later.
Step 2: Slice the potatoes, onion, and ham
Slice the potatoes 1/8-inch thick (a mandoline makes this fast and even). Keep the slices as uniform as possible so they cook at the same rate. Thinly slice the onion and dice the ham into bite-size pieces.
If you’re working slowly, you can hold potato slices in a bowl of cold water to prevent browning. If you do, drain and pat them very dry before layering so your sauce stays thick and creamy.
Step 3: Make a thick, creamy sauce
In a medium saucepan over medium heat, melt 4 tbsp butter. Whisk in 1/4 cup flour and cook for 1 minute, whisking constantly. This cooks out the raw flour taste.
Slowly whisk in 2 1/2 cups milk, then whisk in 1 cup heavy cream. Bring to a gentle simmer, whisking frequently, and cook for 4–6 minutes, until the sauce thickens enough to lightly coat the back of a spoon.
Remove from the heat and whisk in the garlic, Dijon, salt, pepper, thyme, and nutmeg (if using). Taste and adjust seasoning if needed.
Step 4: Layer the casserole
Build layers for even cooking and good sliceable structure:
Add half the potatoes to the dish, overlapping slightly. Scatter half the onion and half the ham over the potatoes. Spoon about one-third of the sauce evenly over the top.
Repeat with the remaining potatoes, onion, and ham. Pour the remaining sauce over the top and gently press down with a spatula so the sauce settles into the layers. (You should still see some potato edges peeking through; that’s fine.)
Step 5: Bake covered until the potatoes are tender
Cover the dish tightly with foil (tight coverage helps the potatoes steam and soften). Bake at 350°F for 1 hour 15 minutes.
When time is up, carefully remove the foil and test tenderness by sliding a thin knife into the center. It should meet very little resistance. If it still feels firm, cover again and bake an additional 10–15 minutes, then re-test.
Step 6: Uncover, reduce, and finish with cheese
Once the potatoes are tender, bake uncovered for 20 minutes to reduce the sauce slightly and encourage browning around the edges.
Sprinkle the top evenly with 2 cups cheddar and 1 cup Gruyère. Bake for 10 minutes, or until the cheese is fully melted, bubbling, and browned at the edges. If you want a deeper golden top, broil on high for 1–2 minutes, watching closely to prevent burning.
Step 7: Rest, slice, and serve
Let the casserole rest for 20 minutes before slicing. This rest time is what turns it from “creamy and loose” into “rich and sliceable.”
Sprinkle with chopped parsley if you’d like a fresh finish. Serve warm.
Pro Tips
- Uniform slices matter: Aim for 1/8-inch potato slices so everything bakes evenly. Too thick and you’ll fight undercooked centers.
- Thicken the sauce on the stove: Don’t rely on the oven alone to thicken. A properly thickened sauce helps the casserole set up and slice cleanly.
- Shred your own cheese: Pre-shredded cheese often contains anti-caking agents that can make the top less smooth and creamy.
- Foil tightness is key: A snug foil seal speeds tenderness by trapping steam. If foil is loose, cook time can increase.
- Rest before cutting: Give it the full 20 minutes so the layers hold together.
Variations
- Extra oniony and sweet: Swap the yellow onion for 2 large shallots, thinly sliced, or add 1/2 cup thin-sliced leeks (well washed).
- Smoky flavor: Use smoked ham and add 1/2 tsp smoked paprika to the sauce.
- Veg-forward version: Replace ham with 2 cups sautéed mushrooms (cooked until browned) and add 2 cups baby spinach (wilted and squeezed dry) between layers.
Storage & Make-Ahead
Refrigerate: Cool completely, cover, and refrigerate for up to 4 days. Reheat covered in a 350°F oven for 25–35 minutes, or until hot throughout (uncover for the last 5 minutes to re-crisp the edges).
Freeze: Wrap tightly and freeze for up to 2 months. Thaw overnight in the refrigerator before reheating.
Make-ahead: Assemble (without baking), cover tightly, and refrigerate for up to 24 hours. Let the dish sit at room temperature for 30 minutes before baking, then bake as directed (you may need an extra 10–15 minutes covered if it’s going in very cold).
Nutrition (per serving)
Approximate, per 1/8 of the pan: 520 calories, 23 g protein, 38 g carbohydrates, 30 g fat, 17 g saturated fat, 3 g fiber, 6 g sugar, 950 mg sodium.

