Preheat the oven to 350 degrees F.
Line a muffin pan with cupcake liners. Set aside.
In a medium bowl, whisk together flour, cocoa powder, baking soda, and salt.
In a large bowl, combine the butter and sugar and beat until light and fluffy.
Beat in the eggs.
Gradually add flour mixture, alternating with buttermilk and vanilla, scraping down the bowl after each addition, until well combined.
Divide the batter into cupcake liners.
Bake for 15-20 minutes or until a toothpick inserted in the center comes out clean.
Cool completely before decorating.