01 - Preheat the oven to 400°F. Line a baking tray with parchment paper.
02 - Toss pumpkin cubes with olive oil, salt, and pepper. Spread evenly on the tray and roast for 25 minutes until golden and tender. Set aside to cool slightly.
03 - Reduce oven temperature to 350°F. Roll out pastry and line a 9-inch tart pan. Trim excess pastry and prick base with a fork. Line with parchment and fill with baking beans. Blind bake for 10 minutes, remove beans and parchment, then bake 5 more minutes until light golden.
04 - In a skillet over medium heat, sauté red onion and garlic in a little olive oil until softened, about 4 minutes. Remove from heat and allow to cool.
05 - In a large bowl, whisk together eggs, crème fraîche or cream, thyme, nutmeg, salt, and pepper. Stir in sautéed onion and garlic.
06 - Arrange roasted pumpkin evenly over the pastry base. Scatter crumbled feta cheese on top, then pour over the egg mixture.
07 - Sprinkle pumpkin seeds over the filling if using.
08 - Bake for 25 to 30 minutes until the filling is set and lightly golden.
09 - Allow tart to cool slightly before garnishing with fresh thyme sprigs. Serve warm or at room temperature.