Sift the cocoa powder, icing sugar and flour into a bowl. Add the butter and rub together until the mixture resembles breadcrumbs. Add the yolks and mix together into a dough..

Shape the pastry dough into a disc, wrap in cling film and refrigerate for 15 minutes.

Preheat the oven to 180˚C/160˚C fan/gas mark 4 and lightly grease a 20cm loose-bottomed tart tin. Roll out the pastry on a floured surface, then use it to line the tart tin. Line with parchment paper and fill with baking beans or rice. Bake for 10 minutes, then remove the paper and beans and bake for another five minutes.

Set a heatproof bowl over a saucepan of gently simmering water, making sure the bottom of the bowl does not touch the water. Add the chocolate and butter to the bowl and leave to melt. Remove from the heat and stir just until smooth. Leave to cool slightly.

Whisk together the eggs, cream, sugar, salt and vanilla in a separate bowl. Whisk the chocolate mixture into the egg mixture until well incorporated.

Pour the filling into the cooled crust. Bake for 20-25 minutes until the edges are set but the centre wobbles slightly when shaken.

Cool completely at room temperature, then chill for four hours. Sprinkle with cocoa powder and serve with whipped cream.