The Messenger of Allah (peace and blessings be upon him) said: "Command children to pray at the age of seven, and when they reach ten years (and do not pray), beat them, and separate their sleeping beds."