The present Hebrew calendar is the product of evolution, including a Babylonian influence. Until the Tannaitic period (approximately 10–220 CE), the calendar employed a new crescent moon, with an additional month normally added every two or three years to correct for the difference between twelve lunar months and the solar year. The year in which it was added was based on observation of natural agriculture-related events in ancient Israel. Through the Amoraic period (200–500 CE) and into the Geonic period, this system was gradually displaced by the mathematical rules used today. The principles and rules were fully codified by Maimonides in the Mishneh Torah in the 12th century. Maimonides' work also replaced counting "years since the destruction of the Temple" with the modern creation-era Anno Mundi.
The Hebrew lunar year is about eleven days shorter than the solar year and uses the 19-year Metonic cycle to bring it into line with the solar year, with the addition of an intercalary month every two or three years, for a total of seven times per 19 years. Even with this intercalation, the average Hebrew calendar year is longer by about 6 minutes and 40 seconds than the current mean tropical year, so that every 217 years the Hebrew calendar will fall a day behind the current mean tropical year; and about every 238 years it will fall a day behind the mean Gregorian calendar year.
The era used since the Middle Ages is the Anno Mundi epoch (Latin for "in the year of the world"; Hebrew: לבריאת העולם, "from the creation of the world"). As with Anno Domini (A.D. or AD), the words or abbreviation for Anno Mundi (A.M. or AM) for the era should properly precede the date rather than follow it.