According to food expert Alton Brown, it takes 3 to 4 hours for fudge to set completely. The time required varies according to room temperature and season, with shorter setting times in the winter.
If fudge fails to harden, undercooking is the likely cause. When fudge is undercooked, it cannot form the sucrose crystals required to give it a solid structure. Before fudge is removed from the heat for beating, the cook must be certain that it has attained the soft ball stage.
To salvage fudge that fails to set, dessert chef Maida Heatter recommends returning the fudge to the stove top, adding a bit more cream, and stirring the mixture once again until it reaches 236 degrees Fahrenheit.