A standard cupcake uses the same basic ingredients as standard-sized cakes: butter, sugar, eggs, and flour. Nearly any recipe that is suitable for a layer cake can be used to bake cupcakes. The cake batter used for cupcakes may be flavored or have other ingredients stirred in, such as raisins, berries, nuts, or chocolate chips.
Because their small size is more efficient for heat conduction, cupcakes bake much faster than a normal layered cake.
Cupcakes may be topped with frosting or other cake decorations. They may be filled with frosting, fruit, or pastry cream. For bakers making a small number of filled cupcakes, this is usually accomplished by using a spoon or knife to scoop a small hole in the top of the cupcake. Another method is to just insert the pastry bag in the middle of the cupcake. In commercial bakeries, the filling may be injected using a syringe. Elaborately decorated cupcakes may be made for special occasions.