At this point, Joshua moves forward quickly and demands to know whether this man is for the host of Israel or for the nation’s enemies. The man replies, “Neither, but as commander of the army of the Lord, I am now come.” We’re told that upon hearing this, Joshua fell down on his face to the ground in reverence. He then asked for orders from this visitor: “What message does my Lord have for his servant?” The commander responds by telling him to take off his sandals, for the place where he’s standing is holy ground—exactly the same words that Joshua’s predecessor, Moses, heard from the burning bush on Mt. Sinai.
We can’t really have any doubt who it is who has confronted Joshua at this point. This is God Himself, perhaps in a pre-incarnate manifestation of the second person of the Trinity. Even though the story merely describes this individual as a man standing with a drawn sword in his hand, still the story itself suggests that this is no mere mortal. If the man were just a man, he would have repulsed Joshua’s attempts to worship him just as Paul and Barnabas rightly repulsed the citizens of Lystra, when they tried to worship them after they had done a miracle in Acts 14.
Joshua rightly recognized that this was a divine visitation, and he acted correctly both in offering Him worship and also in asking what this commander’s instructions were for Joshua. When he asked for that message, I would think that the heavenly visitor gave him the plans for the battle, the very plans that are carried out in the next chapter.
This heavenly visitor identifies Himself as commander of the army of the Lord. Now, it’s natural to think that if He’s the commander of the army of the Lord, it means that He’s the commander of the Jewish troops. And no doubt He was. When He gave His word to Joshua, it would have to do with how the troops would be marshalled for the battle. When Joshua directed them to circle the city of Jericho once a day for seven days, and on the seventh day to circle it seven times, that wasn’t something Joshua dreamed up out of his own head. That must be something that this divine commander told him to do.