Why is my toffee grainy?

im making both treacle and syrup toffee for wedding favors but it keeps going grainy please help
2 answers 2