Why it happens
Cookie dough spreads as the butter melts in the oven, before the flour and eggs have set. The warmer and softer the butter is to start with, the sooner it melts and the further the cookies spread. Too little flour, too much sugar or too much bicarbonate of soda can also make them spread more. Putting dough on a warm or greased baking tray speeds up spreading too.