I can't think of anything regarding the marriage contract that is illegal to agree to within a marriage but that is legal to agree to prior to a marriage.
However, I can think of plenty of stipulations that it would be hard to imagine a reasonable person accepting once they're in a marriage, but that they would reasonably agree to in order to enter a marriage.
E.g., supposing that "if x then I forfeit my marital right to y" is a legal nuptial agreement. For any such x and y I can imagine that clause occurring in a prenuptial agreement. And it would be enforceable under contract law because I suspect that marriage is a form of consideration.
But after the marriage has been established, why would anyone unilaterally forfeit a right? I can only think of twothree reasons:
The forfeit is mutual: I.e., both spouses agree to an identical clause. Or, the spouses agree to substantially equal clauses. (E.g., one spouse forfeits y if x, and the other forfeits b if a; where a·b ≈ x·y.)
One spouse requires the contract as a condition of continuing the marriage. However, I am dubious that this scenario is enforceable. I.e., if I one day say to my spouse, "I'm divorcing you unless you agree to give up your marital right to y," I have a suspicion that such an "agreement" might not withstand an artful legal challenge for several reasons: The consideration I'm offering is something I already pledged. This is like demanding a contract renegotiation once a counterparty has undertaken work. It seems like something that would be ripe for estoppel.
(Thanks to @ohwilleke for noting this one:) The spouse forfeiting a right stands to gain something in exchange. E.g., in order for one spouse to receive an inheritance, the other must disclaim any right to it should the marriage later be dissolved. The spouse is not forfeiting a right already enjoyed, and in consideration of the postnuptial agreement will (potentially) enjoy extra wealth within the marriage.