Preheat oven to 350°F (175°C) and line a standard 12-cup muffin tin with paper liners.
In a large mixing bowl, beat 1 cup softened butter with the granulated sugar for 3-5 minutes until light and fluffy.
Add eggs one at a time, beating well after each addition and scraping down the sides of the bowl.
Mix in vanilla extract and food coloring if desired.
In a separate bowl, whisk together flour, baking powder, baking soda, and salt.
Gradually add the dry ingredients to the wet mixture in three additions, alternating with milk and sour cream, beginning and ending with the dry ingredients. Mix just until combined.
Fill each cupcake liner about ⅔ full using an ice cream scoop or ¼ cup measure.
Bake for 18-20 minutes, rotating the pan halfway through. Cupcakes are done when they spring back when touched and a toothpick inserted comes out clean.
Allow cupcakes to cool in the pan for 5 minutes before transferring to a wire rack to cool completely.
For the frosting, beat butter until creamy, then gradually add powdered sugar alternating with heavy cream.
Add vanilla extract and salt, then beat on medium-high for 3-5 minutes until light and fluffy.
Tint frosting with food coloring if desired and transfer to a piping bag fitted with a decorative tip.
Pipe swirls onto each cooled cupcake and immediately decorate with sprinkles.
Notes
For the best results, make sure all refrigerated ingredients are at room temperature before beginning.
Unfrosted cupcakes can be stored in an airtight container at room temperature for up to 2 days.
Frosted cupcakes should be refrigerated and brought to room temperature before serving.
Nutrition facts are estimates and may vary based on ingredients used, portion sizes, and preparation methods.