Like almost every young adult in America, I was still in student loan debt years after I'd graduated. I also had a house, which thankfully had gone up in value, and which I'd been paying a mortgage on for years. Thanks to the equity built up in my home, I was able to refinance my mortgage to pay off my student loans with my home equity -- but the process was not without pitfalls.

Now, Fannie Mae has announced new guidelines to make it easier to do what I did and take money out of a home to pay off student loans, which typically have a higher interest rate than mortgage debt. While these guidelines can be a boon to homeowners with enough equity who want to say goodbye to student loans forever, there are some pitfalls, and transforming student loan debt into mortgage debt isn't right for everyone.

If you're tired of your student loans and wondering if paying off the debt by taking cash from your house is an option for you, here are a few things you need to know.

Graduate wearing mortarboard with a dollar sign in place of a tassel

Image source: Getty Images.

Fannie Mae's new guidelines make refinancing to pay loans easier

Fannie Mae's new guidelines allow homeowners to refinance an existing mortgage and take out extra money to repay a student loan. If the outstanding balance on the mortgage being refinanced was $180,000, for example, a homeowner could borrow $200,000 and use the extra $20,000 to repay money owed on educational loans.

Cash-out refinancing was always an option; however, under previous guidelines, fees and sometimes higher rates of interest were charged on money borrowed that exceeded the balance of the loan being refinanced. This will no longer be the case, as long as Fannie Mae's rules for student loan refinancing are followed.

These rules require at least one student loan to be fully paid off with the proceeds from the refinance, and require that the borrowed money be paid directly to the student-loan lender. Homeowners are also allowed to take cash out only to pay for loans they have a legal obligation to pay. Parents, for example, could not refinance to pay off a loan that is only in their child's name.

You still need equity to refinance your home

Although Fannie Mae makes refinancing easier, you still cannot refinance unless you have enough equity in your home. Fannie Mae will only allow you to borrow up to 80% of what your home is worth, including the extra money you're taking out to repay your student loans.

You will need to have your home appraised -- which can cost several hundred dollars -- in order to satisfy your lender's requirements that your refinanced mortgage won't exceed 80% of your home's worth. When I refinanced my home, I was confident my home was worth well over the amount needed, but my initial appraisal didn't reflect that. Until my mortgage lender helped me successfully appeal the appraisal, I was worried I wouldn't be able to get enough cash out to pay off my loans.

This could be an even bigger problem with the new Fannie Mae guidelines requiring you to pay off at least one loan in full. While I could have borrowed what was allowed and paid off part of my loans, this wouldn't be the case for someone trying to qualify under Fannie Mae's new refinance rules. If your home doesn't appraise for enough, you could find yourself unable to qualify for the special rules for student-loan mortgage refinancing...and out of the money for the appraisal.

Your interest rate may -- or may not -- be lower after a refinance

Refinancing your home to pay off your student loans makes sense if your mortgage loan will have a lower interest rate than your student loans did. This is typically the case for private student loans, as well as for some federal loans -- especially those which, like mine, were consolidated years ago at a rate above 6%. But, some federal loans may have lower rates than mortgage loans, like the 3.76% rate for direct subsidized undergraduate loans disbursed between July of 2016 and July of 2017.

If you'd be refinancing to a higher rate, you're better off keeping your student loans and not mingling educational debt and mortgage debt. The only exception, if the mortgage and student-loan rates are close to the same: If you deduct your mortgage interest on your taxes and your income is high enough -- $80,000 for single filers as of 2017 -- that you cannot take a deduction for student-loan interest.

You could lose some repayment help by refinancing

There's one other thing to consider before you decide to refinance to pay off student loans: You could lose some of the special benefits available only for educational debt.

Student loans can generally be put into deferment or forbearance if you face financial hardship or go back to school. A mortgage can't, and you won't get a break from your mortgage lender just because you run into financial trouble. With most student loans, you also have the option of choosing income-contingent repayment plans, so you won't struggle too much to pay if your income falls. Mortgage lenders expect you to pay regardless of what happens to your income.

Additionally, some types of student loans are forgiven if you put in enough years of service in an eligible public-interest career. Mortgage lenders, unsurprisingly, will not forgive your mortgage balance because you work in a school serving underprivileged children or take a job in legal aid.

So, before you decide to turn student-loan debt into mortgage debt, make sure you're in a steady job and likely to have a reliable income for years to come...and that you won't be giving up your current career to work in public service any time soon. If you're in a stable place in your life, and you have the equity, it might make sense to consider wiping out your student-loan debt with a new mortgage loan.