Sweet Potato and Caramelized Onion Hash with Baked Eggs

2 tbsp unsalted butter
2 to 3 large yellow onions (about 2 lb), halved, thinly sliced, then halved again
Kosher salt
freshly ground black pepper
3 large sweet potatoes (about 3 lb), skin intact, chopped into 1/4”–1/2” cubes
1/4 cup olive oil
1 1/2 tsp smoked paprika
2 tbsp (packed) finely minced fresh rosemary or oregano leaves
4 to 6 large eggs
shaved Parmesan, for serving (optional)

Preheat oven to 450°. Line a large baking sheet with foil or parchment paper.

Melt butter in a cast-iron or other heavy skillet over medium-high heat. When it foams, add onions and sprinkle lightly with salt and pepper. (Don’t worry if they are crammed into the pan; they will rapidly cook down.) Lower heat slightly and cook, stirring occasionally (reduce heat further if they seem to be burning), until dark brown, about 20-30 minutes.

Meanwhile, toss sweet potatoes, oil, 1 1/2 tsp salt, smoked paprika, a generous helping of black pepper, and minced rosemary or oregano in a large bowl. Stir in onions.

Spread sweet potato mixture on prepared baking sheet and roast for 25-40 minutes, stirring every 10-15 minutes, until sweet potatoes are soft and browned.

Reduce oven temperature to 425°. Spread a relatively thin layer of the cooked sweet potato hash in individual ramekins, a cast-iron skillet, or a 9" x 13" baking dish.

Make small wells in the hash and crack in the eggs. Sprinkle lightly with salt and pepper. Bake for 10-20 minutes, or until hash is hot and eggs are baked to your preference. Test the eggs by prodding them with a fork to check the firmness of the white and the runniness of the yolk.

Serve immediately, with Parmesan, if desired.

Cooks notes:

For variations, try folding in smoked turkey, roasted chicken, or cooked breakfast sausage before roasting.

Hash can be cooled and stored, covered, in the refrigerator for up to 5 days.