Preheat the oven to 350°F (180°C). Line a muffin tin with cupcake liners.
In a bowl, whisk together the flour, baking powder, and salt. Set aside.
In another mixing bowl, cream the softened butter and sugar together until light and fluffy.
Add the eggs one at a time, mixing well after each addition. Stir in the vanilla extract.
Gradually mix in the dry ingredients alternating with the milk until just combined. Do not overmix.
Divide the batter evenly among the cupcake liners, filling each about ⅔ full.
Bake in the preheated oven for 18-20 minutes or until a toothpick inserted in the center comes out clean. Let cool completely on a wire rack.
For the custard filling, heat the milk and sugar in a saucepan until warm (do not boil).
In a bowl, whisk together the egg yolks and cornstarch until smooth. Gradually pour in the warm milk mixture, whisking constantly.
Return the mixture to the saucepan and cook over medium heat, stirring constantly until it thickens. Remove from heat and stir in the vanilla extract and butter. Let it cool.
Once the cupcakes are cool, use a small knife or apple corer to remove some of the center to create a space for the custard filling.
Fill a piping bag with the cooled custard and pipe it into the center of each cupcake.
For the chocolate ganache, heat the heavy cream in a small saucepan until just simmering. Pour it over the chopped chocolate in a heatproof bowl and let it sit for 2-3 minutes.
Stir the ganache until smooth and combined. Allow it to cool slightly, then drizzle or pour over the filled cupcakes.
Let the ganache set before serving. Enjoy your Boston Cream Cupcakes!