Brush four 6 to 8 oz ramekins with soft butter using upward strokes, chill 5 to 10 minutes, then brush a second coat. Dust with cocoa powder, tap out the excess and set on a baking sheet.
Heat the oven to 425°F (220°C) with a rack in the center.
Melt the chocolate and butter in a heatproof bowl over barely simmering water (or in the microwave in 20-second bursts). Stir until smooth and cool for 5 minutes.
Whisk the eggs, yolks and sugar until pale and thickened, 2 to 3 minutes.
Whisk the chocolate into the eggs in two or three additions. Add the vanilla and espresso powder if using, then sift in the flour and salt and fold just until smooth.
Divide the batter between the ramekins, filling each about three-quarters full.
Bake for 8 to 10 minutes, until the tops are set and the edges pull away slightly but the center still wobbles when gently shaken.
Rest for 1 minute, run a thin knife around each cake, invert onto plates and serve immediately with ice cream, crème fraîche or berries.