Exodus 33:5

For the LORD had said unto Moses, Say unto the children of Israel, Ye are a stiffnecked people: I will come up into the midst of thee in a moment, and consume thee: therefore now put off thy ornaments from thee, that I may know what to do unto thee.

Israel is called a stiffnecked people because stubborn rebellion and sin had hardened the heart against God. Because of that condition God warned that if He came up into their midst He would consume them. That consuming destruction would fall in a moment, suddenly.

Therefore God ordered them now to put off their ornaments from them while He determined what to do with them. The putting off was commanded as a sign of mourning over sin and of humbling themselves in repentance, penitence, and humility. In obedience the people stripped off their ornaments by Mount Horeb. They stripped themselves of their ornaments and humbled themselves in penitence because they feared God would destroy them.

The verse belongs to a crisis in which God's people must not harden their hearts against Him but humble themselves. Even in the face of their perversity God's promise remains. He still holds the nation as His people rather than abandoning them.