According to certain traditions, these festivals were initiated in Medina after the migration of Muhammad from Mecca.
For Muslims, both the festivals of Eid al-Fitr and Eid al-Adha are occasions for showing gratitude to Allah and remembering Him, as well as giving alms to the poor.