How do i prevent crystals forming in candle wax?

I have been trying to melt down a store bought candle and pour the wax into a glass. However, when ever I try this, unwanted crystals form in the wax. Does anyone know how I would prevent these forming. Thanks.