Zecharyah / Zechariah 3:2
וַיֹּאמֶר יְהוָה אֶל־הַשָּׂטָן יִגְעַר יְהוָה בְּךָ הַשָּׂטָן וְיִגְעַר יְהוָה בְּךָ הַבֹּחֵר בִּירוּשָׁלִָם הֲלוֹא זֶה אוּד מֻצָּל מֵאֵשׁ׃
And the Eternal said to the Satan: "The Eternal will shout at you, Satan! The Eternal who chose Jerusalem will shout at you! Is not this a brand plucked from the fire?"
Pshat פְּשָׁט
A brand from the fire
Rashi: the Eternal shouts at the Satan twice, so that he does not come before Him to accuse this righteous man: he is worthy and merited being saved from the fire. According to the Talmud, Yehoshua (Joshua) was thrown into the fire together with the false prophets Achav and Tzidkiyahu. Radak: as a burning brand is taken out of the fire so that it burns no more, so he was saved from the fire of exile, to come to Jerusalem, build the Temple and serve in it.
How Rashi and Radak explain it
Remez רֶמֶז
The fire of judgment
Radak: "and the Eternal said" is the angel, who is called by the name of his Master, as in the story of Gideon. And "the Eternal will shout" is the Almighty Himself, blessed is He. Rabbi Yonatan Eybeschutz (Ahavat Yehonatan): the Satan wanted to accuse Yehoshua (Joshua) by the attribute of strict justice, and the angel answered him that fire is the attribute of justice, as it says: "for by fire the Eternal judges". And Yehoshua was saved from the fire.
How Radak and Ahavat Yehonatan explain it
Drash דְּרָשׁ
Singed garments
Talmud (Sanhedrin 93a): the false prophets and Yehoshua (Joshua) were thrown into the fire. They were burned, and the clothes of Yehoshua the high priest were singed. Pirkei DeRabbi Eliezer: the false prophets in Babylon deceived the wives of the Chaldeans, and the king ordered them burned. They said: "Yehoshua was with us in everything", hoping he would save them, and the king ordered all three burned. The angel Michael saved Yehoshua, and his hair was singed for the sins of his companions.
How Talmud, Sanhedrin and Pirkei DeRabbi Eliezer explain it
Sod סוֹד
Not hearing the accuser
Zohar: the Holy One, blessed is He, does not judge the wicked until their sin is complete. That is why the Satan accused Yehoshua (Joshua), that he should burn with them, until the angel of the Eternal said to him: "The Eternal will shout at you, Satan." Ba'al Shem Tov: if the words of the witnesses agree, the court opens with acquittal. So too the merciful Father, even when the accusers are right, opens for us with acquittal. We ask that He not listen to the accusers around the Throne: a witness who wants to accuse is silenced, as it says: "The Eternal will shout at you, Satan."
How Zohar and Ba'al Shem Tov explain it