Preheat the oven to 350℉ (177℃). Line a cupcake pan with 12 cupcake liners.
In a large mixing bowl, whisk together the all-purpose flour, granulated sugar, baking powder, and salt. Add in the milk, vegetable oil, sour cream, egg, and vanilla extract. Whisk until the cupcake batter is combined and smooth. Do not overmix the batter.
Portion the cupcake batter into the cupcake liners using a large cookie scoop, about ⅔ full. Bake the cupcakes for 20 minutes until the tops of the cupcakes bounce back slightly when touched. Cool the cupcakes in the pan for 5 minutes and then transfer to a wire rack to cool to room temperature.
In the bowl of a stand mixer fitted with a paddle attachment or in a large mixing bowl with an electric hand mixer, whip the room temperature unsalted butter for 5 minutes until light, pale, and creamy.
Add in half of the powdered sugar and mix on the lowest speed until the sugar is combined with the butter. Add the remaining half of the powdered sugar and continue to mix on low speed until fully combined.
Add the vanilla extract and salt. While mixing on low speed, drizzle in the heavy cream. Scrape the sides and bottom of the bowl to ensure the ingredients are well incorporated.
Increase the mixer speed to medium and whip the buttercream for about 2 to 3 minutes until it is smooth and creamy.
Optional: To smooth out the buttercream and remove any air bubbles, heat ½ cup of the frosting in the microwave for 15 seconds. Pour the melted frosting back into the mixing bowl and mix the frosting on low speed until the buttercream is super smooth and creamy.
Fill a piping bag fitted with a Wilton 1M piping tip with the vanilla buttercream frosting. Pipe a generous swirl of frosting onto the cooled vanilla cupcakes and decorate with white nonpareil sprinkles, if desired.
