01 - Preheat oven to 375°F and grease a 9x13-inch baking dish.
02 - Melt butter in a medium saucepan over medium heat. Add onions and sauté until softened, about 3 to 4 minutes.
03 - Stir in flour and cook, stirring constantly, for 1 minute.
04 - Whisk in milk and cream gradually. Simmer until sauce thickens, about 3 to 4 minutes. Season with salt, pepper, garlic powder, and nutmeg.
05 - Remove from heat and stir in 1.5 cups of shredded cheddar until melted and smooth.
06 - Arrange half of the sliced potatoes evenly in the baking dish. Pour half of the cheese sauce over the potatoes.
07 - Place remaining potatoes on top, then cover with the rest of the cheese sauce.
08 - Sprinkle with remaining 0.5 cup cheddar cheese and Parmesan cheese.
09 - Cover with foil and bake for 40 minutes. Remove foil and bake an additional 20 minutes until golden and bubbling.
10 - Let rest for 10 minutes before garnishing with chives or parsley and serving.