Making candy is a fascinating hobby, in part because sugar is such a variable ingredient. Depending how you heat and cool it, it can produce a startling range of textures. This is because sugar has an innate tendency to crystallize, and candymakers can manipulate its texture by controlling how and when crystallization occurs. Fudge is a classic example of this, coming out smooth and creamy or gritty and coarse, depending how carefully it's handled.
A Quick Fudge Primer
Fudge is a quintessentially American candy, dating back the late 19th century. The hot sugar is softened and enriched with butter and cream, then flavored with ingredients such as vanilla or chocolate. The basic recipe bears a family resemblance to other candies, such as caramels, which are smoother and chewy, and a Scottish sweet called "tablet," which is firm and grainy. Fudge's distinctively smooth and creamy texture comes from careful control of its temperature while the sugar is heated and cooled.
That Temperature Thing
The first crucial step in making fudge is bringing it to the right temperature. Boiling away the moisture from the cream creates a highly concentrated sugar syrup, and temperature is how you judge the concentration. The ideal temperature for fudge is 236 to 238 degrees Fahrenheit, and no more than 240 F. At this point the syrup is "hypersaturated," meaning it will crystallize at the drop of a hat. Leave the pot stand, untouched, until the temperature of the fudge reaches 110 F, just barely warm. If you beat the fudge thoroughly at that temperature, it will form fine crystals and achieve a smooth texture.
If your fudge finishes with a gritty, sandy texture, the cause is almost always that the fudge crystallized too soon, at too high a temperature. The lower the temperature of your syrup, the finer the crystals the sugar can form. If you begin beating the sugar at too high a temperature -- some recipes even recommend beating it as soon as you remove it from the burner -- it will inevitably become gritty. Should that happen, you have a couple of options for saving the day.
Taking a Do-Over
As long as the fudge isn't burnt, you can take a second shot at making it work. Stir in 1/2 to 3/4 cup of water to thin the mixture, then bring it back to a boil and return it to a temperature of 238 F. Let it cool, more carefully this time, and then beat the fudge for 15 to 20 minutes until it reaches the correct consistency. You might need to add extra flavoring, because some of the volatile flavor compounds will cook out while the fudge is reheating. Alternatively, enjoy the failed fudge as a tasty treat in its own right as a topping for cakes, ice cream or other sweets.