Jesus is born in Bethlehem of Judea in the days of King Herod. Wise men from the east arrive in Jerusalem and ask where the king of the Jews who has been born is, because they saw his star and have come to worship him. Herod is troubled, and so is all Jerusalem. He gathers the chief priests and scribes, who answer from the prophet Micah that the Christ is to be born in Bethlehem. Herod secretly calls the wise men, learns when the star appeared and sends them to Bethlehem, asking them to report back once they find the child, supposedly so he can worship him too.
The star leads the wise men to the place where the child was. Seeing him with Mary his mother, they bow down, worship him and offer gold, frankincense and myrrh. Warned in a dream not to return to Herod, they go back to their country by another route. Then an angel of the Lord tells Joseph in a dream to take the child and his mother and flee to Egypt, because Herod will search for the child to destroy him. Joseph rises by night and leaves. Matthew sees in this the fulfillment of Hosea: out of Egypt I called my son.
When Herod realizes he has been tricked, he orders the killing of all the boys in Bethlehem and its surroundings who are two years old and under. Matthew recalls Jeremiah's words about Rachel weeping for her children. After Herod dies, the angel appears to Joseph again and tells him to return to the land of Israel. Hearing that Archelaus rules Judea, Joseph is afraid to go there and, warned in a dream, withdraws to Galilee, to a town called Nazareth, so that it would be fulfilled that he would be called a Nazarene.