Prepare the Oven and Pans: Preheat the oven to 350°F (177°C), line a 12-cup muffin pan with cupcake liners, and place 2–3 additional liners in a second pan because the recipe yields about 14–15 cupcakes.
Combine the Dry Ingredients: Whisk the flour, baking soda, and salt together in a medium bowl until evenly combined, then set aside.
Mix the Wet Ingredients: In a large bowl, use a whisk, handheld mixer, or stand mixer fitted with a whisk or paddle attachment to combine the oil, creamy peanut butter, brown sugar, egg, sour cream, and vanilla extract.
Finish the Batter: Add the flour mixture, milk, and finely crushed peanuts to the wet mixture, then whisk or beat just until everything is completely combined; avoid overmixing, as the finished batter will be slightly thick.
Fill the Liners: Spoon or pour the batter into the prepared cupcake liners, filling each one only about two-thirds full to help prevent the batter from baking over the sides.
Bake the Cupcakes: Bake at 350°F (177°C) for 21–23 minutes, or until a toothpick inserted into the center comes out clean and the cupcake tops spring back gently when touched.
Cool the Cupcakes: Transfer the baked cupcakes to cool completely before adding the frosting.
Make the Frosting: Beat the softened butter with a handheld or stand mixer fitted with a paddle or whisk attachment on medium speed for about 2 minutes, until creamy.
Add the Chocolate Base: Add the confectioners’ sugar, cocoa powder, and heavy cream or milk, then beat on low speed for 30 seconds.
Add the Peanut Butter: Add the creamy peanut butter, vanilla extract, and salt, then increase the mixer to medium-high speed and beat for 2 minutes, until the frosting is thoroughly combined.
Adjust the Frosting: If the frosting is too thin, add ¼ cup more confectioners’ sugar; if it is too thick, add another 1–2 tablespoons of cream or milk. Taste and add extra peanut butter or a pinch of salt if desired.
Frost the Cupcakes: Once the cupcakes are completely cool, frost them using a piping bag; a basic tall swirl can be created with an Ateco #849 piping tip.
Garnish the Cupcakes: Finish the frosted cupcakes with a mini peanut butter cup or chopped peanuts, if desired.
Make Mini Cupcakes: For approximately 35 mini cupcakes, use the same 350°F (177°C) oven temperature and bake for about 11–13 minutes.
Store the Cupcakes: Cover leftover cupcakes and refrigerate them for up to 5 days.