Cakes are something of a challenge for new bakers trying their wings. When they work, they're wonderful, but there are far too many ways for them to not work. Until you've baked enough cakes to recognize when a batter is at the right consistency or an oven at the right temperature, you'll inevitably have your share of cakes that don't rise at all, or rise too much and crack.
Gluten is a tough, stretchy protein that's formed when flour and water are combined and kneaded. It's a good thing in bread, where the stretchy dough traps air bubbles and helps the loaf rise. It's not as desirable in a cake, where too much gluten can cause the cake to puff up and crack during baking. It also makes the cake chewy and unpleasant. This often happens if you've mixed the batter for too long. Some brands of all-purpose flour have too much protein for some delicate cakes, and you might need to use cake or pastry flour.
Liquid and Flour Imbalance
The same problem can often occur if your recipe doesn't use the correct proportions of liquids and flour. A stiff, doughy batter will often lack elasticity and will crack as the cake bakes and rises. This can happen if the recipe calls for too much flour or too little liquid. The correct ratio is usually to have as much eggs and milk, by weight, as the flour. Commercial recipes are measured in weights, partly for accuracy and partly to make it easier for bakers to make these comparisons mentally.
Temperature and Oven Position
Your cake may bake up into a high, cracked dome if the oven is too hot. The heat of baking activates the baking powder and causes it to release carbon dioxide, which forms bubbles and raises the cake. If the oven is too hot, the upper layer of dough sets and solidifies while the cake is still rising, causing it to crack. This can also happen if you've baked your cake too high in your oven. Use your oven rack at its middle setting, rather than at the top, because hot air rises and the top rack can be too hot.
Your leaveners, whether baking powder or baking soda, can also play a part in causing your cake to crack. If you've used too much baking powder, your cake can rise too quickly and either crack or spill over the sides of the pan. The same can happen with baking soda, if your cake is high in acidic ingredients like buttermilk. Too much baking powder or baking soda will also result in a dry cake with poor texture and flavor. Excessive baking powder leaves a bitter chemical taste, while baking soda gives a soapy flavor and leaves your teeth feeling squeaky.