In the time of Umar it was felt that the Muslims should have a calendar of their own. The question that arose for consideration was as to from which event such era of the Muslims should begin. Many suggestions wore made in this connection. When Umar sought the advice of Ali he advised as follows: "The migration is a turning point in the history of Islam. Prior to migration, the Muslims were a persecuted people, and they had to struggle for survival. It was only after the migration that the Muslims came into their own and were able to establish a polity which became a starting point for the consolidation of Islam. In the defense of Islam, the Ansars have played an important role, and as such the new era should be such wherein both the Muhajirs and the Ansars can share. As such the new Muslim calendar should begin with the Hijra, the day when the Holy Prophet first set his foot in Madina."
Umar accepted the advice of Ali, and the Muslim calendar had its start with the migration of the Holy Prophet to Madina.