Preheat oven to 350 degrees F. If making cupcakes, fill a muffin pan with cupcake papers. If making an 8 inch layer cake, grease two 8 inch pans with nonstick baking spray and place a parchment paper circle in the bottom of each pan.
In a large mixing bowl, add in the chocolate cake mix, cocoa powder, sugar, and instant pudding. Stir with a spatula until combined.
Add in coffee, vegetable oil, eggs, sour cream, and vanilla extract, Whisk until the eggs are incorporated and the batter is smooth.
For cupcakes, fill about ⅔ full with cake batter. Place in the preheated oven and bake for 15 to 19 minutes or until done. Insert a toothpick in the center of one of the cupcakes that's in the center cavity of the pan. If it comes out clean or with moist crumbs, they're done.
For 8 inch cakes, divide the batter into the prepared pans. Spread the batter out evenly. Place in the preheated oven and bake for 30 to 35 minutes or until done. Place a toothpick in the center of the cakes and if it comes out clean or with moist crumbs, it's done.
Let the cakes cool in the cake pan for about 20 to 30 minutes before turning out onto a wire rack to cool completely. The top will be sticky and may stick to the wire rack.
Once cooled, place on a cake board that has about 1 tablespoon of frosting spread on it and frost.