01 - Preheat your oven to 375°F in preparation for baking the eggs.
02 - Heat olive oil in a large skillet over medium heat. Add the finely chopped onion and cook until softened and translucent, approximately 3 minutes. Add minced garlic and stir constantly for 30 seconds until fragrant, being careful not to burn it.
03 - Add the chopped spinach to the skillet. Season with salt, pepper, and nutmeg if using. Cook, stirring occasionally, until the spinach is completely wilted, about 2 minutes. Remove from heat.
04 - Transfer the wilted spinach mixture evenly into four lightly greased 6-ounce ramekins or a single 9-inch baking dish. Spread the spinach to create an even layer.
05 - Using the back of a spoon, create a small indentation or well in the center of each ramekin (or 4 wells if using a single baking dish). Carefully crack one egg into each well, taking care not to break the yolks.
06 - Drizzle approximately 1 tablespoon of heavy cream over each egg. Sprinkle the grated Parmesan cheese generously over the top, ensuring even coverage.
07 - Place the ramekins or baking dish in the preheated oven. Bake for 12 to 15 minutes, or until the egg whites are completely set and opaque while the yolks remain slightly runny. Adjust baking time if you prefer firmer yolks.
08 - Remove from the oven and let the baked eggs rest for 2 minutes before serving. This allows the eggs to finish setting and makes them easier to handle. Serve warm directly from the ramekins or scoop portions from the baking dish.