Positive commandment · Mitzvat Aseh #216 of 613
To marry the widow of one's brother who died childless
לייבם אשת אח
The verse · Devarim 25:5
כִּי־יֵשְׁבוּ אַחִים יַחְדָּו וּמֵת אַחַד מֵהֶם וּבֵן אֵין־לוֹ לֹא־תִהְיֶה אֵשֶׁת־הַמֵּת הַחוּצָה לְאִישׁ זָר יְבָמָהּ יָבֹא עָלֶיהָ וּלְקָחָהּ לוֹ לְאִשָּׁה וְיִבְּמָהּ
“If brothers dwell together, and one of them die, and have no child, the wife of the dead shall not marry abroad to a stranger: her husband’s brother shall go in to her, and take her to him to wife, and perform the duty of a husband’s brother to her.”
The Rambam’s words
To marry the widow of one's brother who died childless, as [Deuteronomy 25:5] states: "Her yavam shall come unto her."
לייבם אשת אח, שנאמר: "יבמה יבוא עליה" (דברים כה,ה).
Why · Sefer HaChinuch #598
Levirate marriage
“It is from the roots of the commandment [that it is] since the woman that a man marries, behold, she is like one of his limbs — as so does nature necessitate because of the story of the first father, as one of his ribs was taken and from it did G-d build woman — and since this man died with no sons, that there should be a portion from him for his memory and to fill his place in the world in the service of his Creator.”
Who & when
“And this commandment is practiced in every place at all times by males.”
Where in the Mishneh Torah
Hilchot Levirate Marriage and Release הלכות יבום וחליצה