Cheesecakes are not technically a cake at all, which may contribute to why they crack so often. They are closer to a custard, which is another dessert that has problems with cracks because of the nature of the eggs that are used in them. Though cracks don't affect the taste, a cracked cheesecake is unsightly. There are a few ways to try and prevent the cracks from happening.
Mixing the Batter
In order to prevent cracks, you should only mix the batter as much as your recipe says. For example, if your recipe says "mix until combined," then you should only mix until combined and no longer. Mixing for longer than this causes air to seep into the batter. The air causes the batter to rise while baking. The rising is only temporary though, and it will eventually fall, causing cracks. Never overdo the mixing of the batter.
Traditionally, a water bath was used to make cheesecakes because it would help keep the cheesecake moist as it cooked, which helps prevent cracks. But a water bath takes a long time, and most modern day cooks use a dry baking method at a higher temperature to bake the cheesecake faster. This zaps moisture out of the batter, causing cracks. To avoid this, bake your cheesecakes at a lower temperature if at all possible. You could also place a shallow pan of water on the bottom rack, which humidifies the oven. Or, try a recipe that calls for a water bath and let the cheesecake bake the old fashioned way.
Baking a cheesecake using the methods in Step 2 may not always be possible. There will be times when you absolutely must bake it faster. A good way to try and prevent cracks even when cooking at a higher temperature is to add cornstarch to the batter before baking. Just add 1/4 cup cornstarch to the batter at the same time as the sugar, and follow the rest of the recipe as written. The cornstarch helps prevent the eggs from over-coagulating, which may help prevent cracks in the cheesecake.
Run a Knife Around the Perimeter
Sometimes you will pull a cheesecake out of the oven and it looks perfect, with no cracks. You return after letting it cool and are shocked to find cracks. This is because a cheesecake contracts while it is cooling. If the edges are stuck to the side of the pan, they will not contract with the rest of the cake, forming cracks. Run a knife around the entire perimeter of the cake right after you take it out of the oven to help prevent cracks from forming during contraction.