A day is defined by Earth's rotation on its axis, which takes approximately 24 hours to complete one full rotation. This rotation creates the cycle of day and night as different parts of Earth face toward or away from the sun. It's unrelated to the moon's orbit (about 27 days) or Earth's revolution around the sun (365 days).