Improving on the sundial the Egyptians used a merkhet, the oldest known astronomical tool. The exact design for the merkhet consists of a horizontal bar, carved from wood or bone. A plumb-line hangs from a transverse hole at one raised end of the bar, this being attached to a controlling wooden handle. To operate properly, two merkhets are required, one aligned with Polaris (North Pole) star. By observing the transits of certain stars as they crossed the meridian and came into alignment with the two merkhets, time could be estimated very accurately.
The Egyptians also developed water clocks, most likely used in the Precinct of Amun-Re. Outside of Egypt, the Ancient Greeks called them clepsydrae. These outflow water clocks were believed to have been introduced from Mesopotamia, maybe even as early as 2000 BC to the Shang Dynasty of Ancient China.
Around 3000 BC Mesopotamia began to standardize the hour. And following the Egyptians 24 hour day, ancient Sumerians, also based their number system on 12. Approximately a 12 hour day and a 12 hour night was standardized so they would no longer exactly correspond to the Sun, but remain consistent throughout the year.