Prep the air fryer and ramekins: Preheat the air fryer to 375°F (190°C) for 3–5 minutes. Generously grease the ramekins with butter or spray, then dust with cocoa powder, tapping out the excess. This prevents sticking and helps the cakes release cleanly.
Melt chocolate and butter: In a heatproof bowl, melt the chopped chocolate and butter together. Use a microwave in 20–30 second bursts, stirring between each, until smooth. Let it cool for 1–2 minutes so it’s warm, not hot.
Whisk eggs, yolks, and sugar: In a separate bowl, whisk eggs, yolks, and sugar until slightly thick and pale, about 30–45 seconds by hand. Add vanilla and salt.
Combine mixtures: Stream the warm chocolate-butter mixture into the egg mixture while whisking. Stir until glossy and uniform.
Add flour: Sift in the flour and gently fold with a spatula until just combined. Do not overmix—stop as soon as no streaks remain.
Fill ramekins: Divide the batter evenly among prepared ramekins, filling each about 3/4 full. For extra insurance on the molten center, tuck a square of chocolate into the center of each and cover with a little batter.
Air fry: Arrange ramekins in the air fryer basket with space between them. Cook at 375°F (190°C) for 7–9 minutes. The edges should be set and slightly puffed; the centers should look soft and jiggle lightly.
Rest briefly: Let the cakes rest for 1 minute. Run a thin knife around the edges.
Invert and serve: Place a small plate over each ramekin, invert, and lift off the ramekin. Dust with powdered sugar and serve immediately with ice cream or berries.
Doneness tip: If your air fryer runs hot, start checking at 6 minutes. If the tops are fully set with no jiggle, they may be overdone; reduce time on your next batch.