After Herod died, an angel of the Lord suddenly appeared in a dream to Joseph in Egypt,
References for Matthew 2:19
saying, "Get up! Take the child and His mother and go to the land of Israel, because those who sought the child's life are dead."
So he got up, took the child and His mother, and entered the land of Israel.
But when he heard that Archelaus 6 was ruling over Judea in place of his father Herod, he was afraid to go there. And being warned in a dream, he withdrew to the region of Galilee.
References for Matthew 2:22
Then he went and settled in a town called Nazareth to fulfill what was spoken through the prophets, that He will be called a Nazarene.