01 - Heat the oven to 350°F.
02 - Line a 9-inch tart pan with the shortcrust pastry, trimming any excess. Prick the base with a fork and chill in the refrigerator for 10 minutes.
03 - Heat olive oil in a large skillet over medium heat. Add finely chopped onion and sauté for 3 to 4 minutes until softened. Add minced garlic and cook for an additional minute.
04 - Add chopped spinach to the skillet and cook until wilted and excess liquid has evaporated. Remove from heat and allow to cool slightly.
05 - In a large mixing bowl, whisk together eggs, crème fraîche or heavy cream, nutmeg, salt, and pepper until smooth. Fold in the cooled spinach mixture, crumbled feta, and half of the grated Gruyère cheese.
06 - Pour the filling into the chilled pastry shell. Sprinkle the remaining Gruyère evenly over the top.
07 - Bake in the preheated oven for 35 to 40 minutes until the filling is set and the top is golden brown.
08 - Allow the tart to cool for 10 minutes before slicing and serving.