Dear Moneyist,

Before I married my wife two years ago, she had huge amounts of debt to her name, including large amounts of student loans. After we married, we diligently almost paid everything off, helped by my salary being three times that of my wife.

She recently asked for a divorce, saying she was taking the house and my retirement. My question is: Does the fact we paid off her debts she held before get spread evenly? Had I not paid all of her debts our net worth would be near the same with a better outcome for me.

Read also:Behold, the biggest financial secret to a happy marriage

We’ve only been married a few years, and frankly I can’t help feeling taken advantage of. The only advice I can find discusses whose responsibility the student loans would be, but now it just seems that she got me to pay all of her debts, and got some new stuff, while I threw away years of my life.

Please tell me there’s hope.

Squeezed in Fort Worth

Dear Squeezed,

I’m sorry you feel squeezed or played. But I can’t argue with that. After two years, that’s a tough break, especially given all the help you gave your wife with her student debt. That’s a particularly unusual kind of debt, in that it’s virtually impossible to discharge. So if your wife was planning to wipe out some debts with your help before she filed for divorce two years after your marriage, that was the one to wipe out first.

The good news: Texas is a community property state so, where you have not co-mingled your assets, you take out of the marriage what you brought into it. Unfortunately, that doesn’t include the money you gave your wife to pay off her loans. But if you had a home before you married, for instance, you will walk away with that. Document all your financial transactions with your wife. The court has discretion to divide community property in a way it deems fair and reasonable.

Don’t miss:My stepmother stole money owed to me — how do I find my late father’s will?

Typically, the court will divide retirement plans equally between the two soon-to-be former spouses. Given the short length of your marriage and the help you gave your wife paying off her student loans, you certainly have a good chance of fighting this particular rule. You may not be entirely successful, but a good divorce attorney will advise you on how to approach this delicate matter. Your wife is divorcing you, after all, and where there is flexibility in the law, there is opportunity.

I posted your question in the Moneyist Facebook Group and the members also cited the short period of marriage, the importance of choosing a good divorce lawyer, the perils of mediation (given that you have a relatively strong hand walking into divorce court) and a forensic accountant to examine your retirement accounts both before and during your marriage. All good advice.

The best thing you have going for you right now is your honest intentions going into this marriage and your (good) behavior throughout. Having examined all the details, the judge may not be able to say the same thing about your wife.

Teenagers, just like their parents, want iPhones more than ever

Recommended:After my father died, my brother has been pressuring me to lend him money

Do you have questions about inheritance, tipping, weddings, family feuds, friends or any tricky issues relating to manners and money? Send them to MarketWatch’s Moneyist and please include the state where you live (no full names will be used).

Would you like to sign up to an email alert when a new Moneyist column has been published? If so, click on this link.