God said to Jacob, "Get up! Go to Bethel and settle there. Build an altar there to the God who appeared to you when you fled from your brother Esau."
References for Genesis 35:1
So Jacob said to his family and all who were with him, "Get rid of the foreign gods that are among you. Purify yourselves and change your clothes.
We must get up and go to Bethel. I will build an altar there to the God who answered me in my day of distress. He has been with me everywhere I have gone."
References for Genesis 35:3
Then they gave Jacob all their foreign gods and their earrings, and Jacob hid them under the oak near Shechem.
When they set out, a terror from God came over the cities around them, and they did not pursue Jacob's sons.
References for Genesis 35:5
So Jacob and all who were with him came to Luz (that is, Bethel) in the land of Canaan.
Jacob built an altar there and called the place God of Bethel because it was there that God had revealed Himself to him when he was fleeing from his brother.
References for Genesis 35:7