Bereshit / Genesis 38:26 · Remez
וַיַּכֵּר יְהוּדָה וַיֹּאמֶר צָדְקָה מִמֶּנִּי כִּי־עַל־כֵּן לֹא־נְתַתִּיהָ לְשֵׁלָה בְנִי וְלֹא־יָסַף עוֹד לְדַעְתָּה׃
Yehudah recognised [them] and said: "She is right, it is from me. For I did not give her to my son Shelah." And he was not intimate with her again.
Remez רֶמֶז
A confession that opens the way for others
When someone is the first to admit a mistake aloud, it becomes easier for others to admit theirs. And sometimes a person uses cunning, but for a good aim. How should such a deed be judged?
Da'at Zekenim: a human court executes one who confesses, but God has mercy on one who confesses and forsakes his sin. Seeing Yehudah (Judah) confess, Reuven (Reuben) confessed his sin. So in the blessing of Moshe (Moses) Reuven and Yehudah stand one after the other, although by age Shimon (Simeon) and Levi come between them. Sforno: Tamar acted by deceit, but for an aim pleasing to God. "Greater is a sin for the sake of Heaven than a mitzvah not for its sake."
How Da'at Zekenim and Sforno explain it
Da'at Zekenim And he said: she is right, from me
The judgment of the Holy One is not like the judgment of people. A man stands before a judge: if he confesses his crime, he is executed. But the Holy One: "one who confesses and forsakes [his sin] shall find mercy" (Mishlei / Proverbs 28:13). And as soon as Reuven saw that Yehudah had confessed, he stood up and confessed that he had defiled his father's bed. That is what Elifaz (Eliphaz) said to Iyov (Job): "what wise men have told and not hidden from their fathers" (Iyov / Job 15:18): these are Yehudah and Reuven. "To them alone the land was given, and no stranger passed among them" (Iyov / Job 15:19). And therefore, when Moshe our teacher blessed them, there is no one between them [Shimon is missing from the blessing, and Levi comes after Yehudah], as it says: "Let Reuven live and not die" and so on, "and this for Yehudah, and he said: hear" (Devarim / Deuteronomy 33:6–7). Behold, no stranger passed among them.
Sforno She is right, from me
Though she came to me by deceit, and I did not see her at all, for I sent the kid, still she is righteous in her deceit, for it was for a good aim, pleasing to God, namely the continuation of the line, not for her own pleasure, for she went straight back to her widowhood. She is more righteous than I was in keeping my word, for my aim in it was my own honour and getting back my pledge, which is a worthless and lowly aim. As the sages said: "greater is a sin for the sake of Heaven than a mitzvah not for its sake".
Takeaway
Moshe's blessing (Devarim / Deuteronomy 33): Reuven (33:6), right after him Yehudah (33:7), then Levi (33:8). Shimon (Simeon) is left out. Da'at Zekenim sees in Reuven and Yehudah standing together the memory of their confessions.
Reuven's sin with Bilhah, his father's concubine: Bereshit / Genesis 35:22.
"Greater is a sin for the sake of Heaven" is said by Rav Nachman bar Yitzchak (Nazir 23b). The Talmud at once corrects it: not "greater than" but "like a mitzvah not for its sake", and gives the example of Yael (Jael), who killed Sisera.