The Israelite soldiers, along with the priests who are carrying the ark, have marched a circle around the city of Jericho once a day for six days in a row. The Lord told Joshua that on the seventh day they are to march around the city seven times, the priests are to give a loud blast on their trumpets, all the men are to raise their voices in a shout, and the wall will fall. It's time to complete the seventh day of the Lord's unusual battle plan.
Does this mean the Israelites took the city of Jericho on the Sabbath? We are not told that they took a day off from encircling Jericho, so one of the seven days had to have fallen on the Sabbath, but not necessarily the day they did the work of capturing the city and overcoming its soldiers. But even if they did take the city on the Sabbath, the Lord is Lord of the Sabbath (Matthew 12:8) and if He commanded the men to march on that day of the week then they were not sinning against Him. The rule about not working on the Sabbath was made for man's benefit, not the Lord's. (Mark 2:27) The Lord is not constrained by rules He made for man regarding the Sabbath. He rested from His work of creation on the seventh day but the Bible makes it clear that He is busy with other work every single day on behalf of mankind: When Jesus was criticized for healing on the Sabbath, He said, "My Father is always at His work to this very day, and I too am working." (John 5:17)
By the seventh day the citizens of Jericho were getting used to the Israelites appearing just after sunup and making a circuit around their city and then going back to camp. But on the seventh day, something different happens. "On the seventh day, they got up at daybreak and marched around the city seven times in the same manner, except on that day they circled the city seven times." (Joshua 6:15)
I think the nerves of the soldiers and guards of Jericho were already strained to the breaking point. It was a form of psychological warfare the Israelites were carrying out against them each day, but imagine how much more anxious they felt when the Israelites did not depart on the seventh day after circling the city once. Based on the estimated size of the city of Jericho, and based on the size of Israel's army, scholars think each circuit would have taken about an hour. If that's the case, on the seventh day the soldiers and priests of Israel spent seven hours going around the walls of Jericho. We were told the Israelites camped at Gilgal in the first month of the Jewish calendar (the month of Nisan) which is in the spring. Daybreak was probably around 6:30, so if it took the Israelites seven hours to encompass the city seven times, it was about 1:30 in the afternoon when the shout went up and the walls fell. After seven long, fearful hours of watching these men circle the walls, I think the hearts of the soldiers of Jericho were fainting within them. I think they lost a lot of their confidence in their ability to fight. I think they were calling out to their gods and their gods weren't answering. I think the psychological warfare accomplished its purpose and that the men of Jericho were unable to put up as good of a fight as they might have done under other circumstances.
"The seventh time around, when the priest sounded the trumpet blast, Joshua commanded the army, 'Shout! For the Lord has given you the city!'" (Joshua 6:16) They are to shout before the wall falls. They are to shout in faith.
Joshua continues, "The city and all that is in it are to be devoted to the Lord. Only Rahab the prostitute and all who are with her in her house shall be spared, because she hid the spies we sent. But keep away from the devoted things, so that you will not bring about your own destruction by taking any of them. Otherwise you will make the camp of Israel liable to destruction and bring trouble on it. All the silver and gold and the articles of bronze and iron are sacred to the Lord and must go into His treasury." (Joshua 6:17-19) The city is full of idols and objects and substances used in idolatrous practices. They are to have nothing to do with these things. They also are not to covet the valuable items of silver and gold and bronze and iron; these belong to the Lord. In addition, they are not allowed to do on this occasion what they have been allowed (and will be allowed sometimes in the future) to do when conquering a city: they are not to kill only the men of Jericho and take the women and children captive. The entire city and everything in it will be destroyed other than the items destined for the Lord's treasury. The only exception is that the two Israelite spies are to save the life of Rahab and the lives of her family members who are in the house with her.
"When the trumpets sounded, the army shouted, and at the sound of the trumpet, when the men gave a loud shout, the wall collapsed; so everyone charged straight in, and they took the city. They devoted the city to the Lord and destroyed with the sword every living thing in it---men and women, young and old, cattle, sheep and donkeys. Joshua said to the two men who had spied out the land, 'Go into the prostitute's house and bring her out and all who belong to her, in accordance with your oath to her.' So the young men who had done the spying went in and brought out Rahab, her father and mother, her brothers and sisters and all who belonged to her. They brought out her entire family and put them in a place outside the camp of Israel." (Joshua 6:20-23)
Rahab did just as the men instructed her; she hung a scarlet cord from her window so her house was easily discernable from all the other houses during the heat of battle. The men kept their word and rescued her and everyone in the house with her. For the time being, until purification rituals can be undertaken to make Rahab and her family ceremonially clean, they will reside outside the camp. But at some point after having joined the congregation of Israel, Rahab becomes the wife of Salmon of the tribe of Judah. She becomes the mother of Boaz and the grandmother of Obed and the great-grandmother of Jesse and the great-great-grandmother of King David. This is how the Lord redeems a person's past! Not only did He save the life of this woman who put her faith in Him, He saved her soul, redeemed her past, and gave her a place in the royal family of Israel. He put her in the lineage of His own Son, for in Matthew 1 we read the genealogy of Jesus of Nazareth and there we find the name of Rahab of Jericho. There we find the name of a woman who once was a heathen prostitute but who, by faith in the one true God, was redeemed in every way from who she used to be. If the Lord can take an immoral idolater and change her heart and give her a place in His own family, He can do the same for anyone! There is nothing in your past or mine that the Lord cannot redeem!
"Then they burned the whole city and everything in it, but they put the silver and gold and the articles of bronze and iron into the treasury of the Lord's house. But Joshua spared Rahab the prostitute, with her family and all who belonged to her, because she hid the men Joshua had sent as spies to Jericho---and she lives among the Israelites to this day." (Joshua 6:24-25) The events of the book of Joshua were written soon after they took place, for Rahab was still alive when the book was written.
"At that time Joshua pronounced this solemn oath: 'Cursed before the Lord is the one who undertakes to rebuild this city, Jericho: 'At the cost of his firstborn son he will lay its foundations; at the cost of his youngest he will set up its gates.' So the Lord was with Joshua, and his fame spread throughout the land." (Joshua 6:26-27) Jericho must have been an exceedingly wicked city. There will be times when citizens of a conquered city are to be saved and/or plunder taken from it by the Israelites. There will be other times when everything in a city must be destroyed because the risk of infection by evil is too great. The lure of whatever went on in that city is too compelling. This was the case with Jericho and, because it was such a wicked place, Joshua pronounces a curse upon anyone who undertakes to rebuild it. Unfortunately, his words won't be taken to heart. During the reign of Ahab king of Israel, a man named Hiel of Bethel will rebuild Jericho. The Bible says, "He laid its foundations at the cost of his firstborn son Abiram, and he set up its gates at the cost of his youngest son Segub, in accordance with the word of the Lord spoken by Joshua son of Nun." (1 Kings 16:34) We don't know by what manner Hiel's sons lost their lives. Since Hiel lived during the reign of one of Israel's most wicked and idolatrous kings, it could be he performed what was known as "foundation sacrifices": a heathen practice in which a man undertaking a building project would sacrifice a son to his pagan gods and place the body of his son in the foundation of the wall, gate, or house he was building. This foundation sacrifice was supposed to cause his pagan gods to grant protection and favor upon the city or house. Whatever the cause of Hiel's sons' deaths, Joshua spoke prophetically about their demise centuries earlier.
The Lord was with Joshua and caused the Israelites to esteem Joshua highly as God's chosen leader. The Lord caused the fame of Joshua and the news of the defeat of Jericho to spread far and wide throughout the land of Canaan. Long before the army of Israel engages any of the other armies of Canaan in battle, those soldiers will have heard of the success of the Israelite army and the power of Israel's God---the God before whom walls fall, the God before whom waters part, the God before whom no wickedness can stand.