The Israelites lived peacefully in Egypt for many years until a new pharaoh enslaved them. The Bible tells how a leader named Moses led the Israelites out of Egypt. According to the Bible, God helped the Israelites escape from slavery. The Jewish festival of Passover celebrates their deliverance, called the Exodus. According to tradition, God dictated His laws to Moses in a collection of teachings called the Torah after the Israelites left Egypt.
Most scholars believe the Torah was written down much later.
The Bible says that after receiving the Torah, the Israelites wandered in the wilderness for 40 years. Moses died before his people entered Canaan, but his successor, Joshua, led them into their old homeland. For about 200 years, the Israelites struggled to reestablish themselves in Canaan. They fought the Canaanites, the Philistines, and other peoples. This time is known as the period of the Judges.