Why does the Earth Spin?

Earth experiences gravitational force of many stars & planets. Hence it revolves and spins. It revolves around the Sun as it is main source of Gravity for Earth.