Deuteronomy 25:9

Then shall his brother’s wife come unto him in the presence of the elders, and loose his shoe from off his foot, and spit in his face, and shall answer and say, So shall it be done unto that man that will not build up his brother’s house.

This law is that of levirate marriage for the case of a man who dies without son, children, or heir, requiring his brother and more broadly his Goel or nearest kinsman to marry the widow and raise up seed, offspring, and a house for the dead man. Deuteronomy 25:5-10 gives the statute, and Deuteronomy 25:7-10 sets out the procedure by which the widow can call upon the nearest kinsman to perform it. Its purpose was to preserve the dead man's name, family, inheritance, land, and homestead in Israel and in Canaan so that no family should perish, with the firstborn son counted as the dead man's son and heir to inherit his land. The duty is connected with the right of redemption belonging to the nearest of kin, so that the near kinsman acts as Goel or redeemer. As such Boaz accepted the duty and redeemed the inheritance to preserve Elimelech's family name.

If the kinsman refuses, the widow in the presence of the elders looses his shoe from his foot, spits in his face, and pronounces that so shall it be done to the man who will not build up his brother's house. This brings him public insult, shame, contempt, and a reproachful name, with the removal of the shoe and the spitting marking the utmost contempt for refusing to perpetuate the dead kinsman's family and inheritance. Refusal brings both human contempt and the Lord's displeasure, as shown by the death inflicted for refusal in Genesis 38. Only the first son of such a union was reckoned the dead man's son, while later sons belonged to the living kinsman himself. If therefore only one son was born the living kinsman would be left reckoned childless without an heir to preserve his own name and family and would mar his own inheritance, which explains the refusal of the nearer kinsman in Ruth 4.

The law did not originate with Moses but existed in germ and in special form and was recognized in patriarchal times, as proved by the conduct of Judah's family in Genesis 38, showing the ante-Mosaic origin of the so-called Mosaic laws. Under that law Tamar's strategy was an effort to secure rights guaranteed by law and custom after Judah defrauded her of them, making her conduct less reprehensible in those circumstances. Her sons were reckoned legitimate, and one stands in the ancestry of Christ. The law supplies the marriage custom behind the Sadducees, who say there is no resurrection, posing the case of seven brothers who one after another married the same childless widow and asking whose wife she shall be in the resurrection, a question based on this obligation to take the deceased childless brother's wife and raise up seed unto him.

Jesus answered that they erred, not knowing the Scriptures nor the power of God, showing that all difficulty about how the dead are raised comes from lack of knowledge of the Scriptures and of the power of God by which the dead are raised. The inheritance-preserving arrangement is unnecessary after the resurrection, because those who receive the everlasting inheritance will not die and their inheritance will not pass to another.