Start by peeling and finely slicing the onions. Look for onions that are firm and fresh, as they will bring the best flavor to the dish.
In a large saucepan, heat the olive oil and butter together over medium heat. This combination helps to create a rich base for the onions.
Add the sliced onions, salt, and sage to the pan. Cook for about 10 minutes, stirring occasionally until the onions start to soften. You want them to become translucent but not browned yet.
Turn the heat down to its lowest setting and continue to cook the onions for about 30 minutes, stirring occasionally. You’re aiming for a golden-brown color, which indicates they’ve caramelized beautifully.
While the onions are cooking, remove the puff pastry from the freezer and set it on the counter to defrost. It’s important that the pastry is thawed but still cold when you work with it.
Add the balsamic vinegar and brown sugar to the onions. Stir well and cook for an additional 10 minutes, allowing the flavors to meld together.
Slide your defrosted puff pastry onto a baking sheet lined with cooking paper. Make sure it’s positioned correctly, as this will be the base for your tart.
Preheat your oven to 220°C/430°F. This high temperature will help achieve that perfect puffiness and golden color.
Using a butter knife, carefully cut a border inside the tart, about an inch from the edge. You want to score it gently without cutting all the way through. This will help the edges rise while keeping the filling intact.
Prick the surface of the inner rectangle of the pastry with a sharp knife. This helps to minimize puffiness during baking and ensures an even base for your filling.
Spread the caramelized onion mixture evenly over the inside of the tart. If you find you have more filling than space, don’t worry – it keeps well in the fridge!
Sprinkle the crumbled feta cheese (or goat's cheese) generously over the onion mixture. The cheese will melt and create a delightful creamy texture.
Using a pastry brush, glaze the edges of the tart with the beaten egg. This helps create that golden brown color during baking.
Bake for about 20 minutes, or until the tart is crispy and golden. Your kitchen will smell amazing by this point!