Refinancing a mortgage at a lower interest rate isn't always the right decision. Having bragging rights at the neighborhood picnic isn't a reason for refinancing a mortgage. Instead, it's good to put some thought behind the timing of your decision.

Refinancing a mortgage multiple times can reduce your overall financial benefit. Refinancing junkies who always migrate to the next low mortgage rate pay a hefty price by leaving a trail of closing costs in their wake.

In some cases, refinancing a mortgage makes sense. In other cases, it may be more prudent to stick with your current loan.

What's your goal?

Before deciding whether to refinance, you need to determine what you want to accomplish. Remember, refinancing a mortgage doesn't pay off the debt; it just restructures it, often at a lower interest rate and a different loan term than the current mortgage.

Reducing the interest expense is the most common goal of a refinance. But some homeowners also appreciate the ability to extend the loan back out to 30 years, reducing the monthly payment.

Debt consolidation is another goal of refinancing. If you have both a first mortgage and a home equity loan, combining the two mortgages into one fixed-rate mortgage levels out the payment over the loan term.

Refinancing tip: Do it once

Ideally, you only want to refinance once on your current mortgage. While no one can tell you with certainty where interest rates are going, Bankrate's weekly Rate Trend Index and Mortgage Analysis will keep your finger on the pulse of where interest rates are headed. You can have them delivered as a weekly e-mail so you don't have to remember to look for the columns.

Many homeowners refinance because they want to get out of (or into) an adjustable-rate mortgage. In high interest rate environments, homeowners are attracted to ARMs because they typically are at a much lower interest rate than a 30-year fixed-rate mortgage.

On the other hand, in low interest rate environments, the differential between the fixed-rate and the ARM isn't as great, and homeowners like the security of locking in a fixed rate over the mortgage term.

When to refinance

After clarifying your reasons for refinancing a mortgage, you need to consider whether the timing and circumstances make this the right time to get a new loan.

Usually, you have to plan to be in the house for a while for refinancing to make sense, says Charles Delaney, associate professor of finance, and director of the real estate program at the Hankamer School of Business at Baylor University in Waco, Texas.

"You have to look at the savings relative to the cost, and then consider: How long am I going to be in this property?" he says.

According to Bankrate's 2012 closing cost survey, the national average for closing costs on a $200,000 loan was $3,754. The fees in the survey don't include taxes, insurance or prepaid items such as prorated interest or homeowner association dues.

When weighing whether to refinance, homeowners typically are urged to consider how many months of lower payments it will take to recoup the closing costs of the new mortgage.

Refinancing tip: Know where you stand

Before you refinance, know where you stand with your current mortgage -- including the loan terms and interest rate, as well as relevant factors such as your credit score and whether or not the loan has a prepayment penalty.

For example, if your monthly payment goes down by $157, it would take 24 months of lower payments to recoup the average closing costs. Bankrate's refinancing calculator lets you input your costs and the loan terms to calculate the months it will take to recoup your costs.

Refinancing costs

$157 lower monthly payment x 24 months = $3,700+ closing costs

While this is not a bad rule of thumb, it doesn't really measure your savings. Savings come from a lower interest expense, not lower monthly mortgage payments. Bankrate's refinancing calculator shows the change in total interest expense, too.

You'll see that if you get a lower interest rate but extend the mortgage term, you can wind up spending more in interest. For example, replacing a mortgage that has 20 years remaining with a 30-year mortgage will result in higher interest expense over the life of the new loan.

To figure out whether refinancing with a loan term extension will help you save, do two calculations: one where the new loan has the same term as the old loan, and one where the new loan is the length of your planned refinance. Compare the interest savings to see if refinancing accomplishes your financial goal.

Some people refinance simply to make the monthly mortgage payment more affordable. A lower interest rate and/or a longer loan term both work toward lowering the monthly payment. As long as the homeowners understand they may not be minimizing total interest expense, affordability can be a motivation for extending the loan term.

While short-term savings are important, they are not the only factor to weigh when considering a refinance. Refinancing to get out of an ARM, piggyback mortgage, interest-only mortgage or other onerous mortgage provisions may be reason enough to take on a refinancing.

However, in some cases, homeowners with ARMs would be fine sticking with their loan, especially if they don't plan on being in the loan long term and the reset rate on their mortgage isn't financially threatening.

When not to refinance

On the other hand, a little number crunching may indicate that refinancing a mortgage is not right for you at this time.

If you don't plan to be in the house for very long, you should probably stay in your current mortgage. Here, the number of months it takes to recoup closing costs becomes the more important calculation done by the refinancing calculator.

Refinancing tip: Consider a mortgage broker

A mortgage broker is truly needed if you have a "story loan" -- in other words, you have to sell your story to the lender in order to get approved for the loan.

If you owe more on the house than it's currently worth -- you're underwater, in the lingo of the mortgage business -- you might be able to refinance under the Home Affordable Refinance Program, or HARP. This refi program is for homeowners who are current on their mortgages.

Type of refinancing

The two major types of refinances are cash-out refinancing and standard "plain vanilla" refinancing, where you are just refinancing the existing mortgage balance.

In a cash-out refinancing, you take out a new mortgage on the same property in which the amount borrowed is greater than the amount of the previous mortgage. The difference is taken out in cash.

A cash-out refinance will typically have a slightly higher interest rate than a plain vanilla refinancing because the lender has more money at risk. Cash-out refinances often are used to pay down debt, but this type of mortgage has both pros and cons.

For example, imagine that you use a cash-out refinance to pay off credit card debt. On the pro side, you're reducing the interest rate on the credit card debt and freeing up lines of credit on your credit cards.

On the con side, you may pay thousands more in interest expense because you're taking 30 years to pay off the balance you transferred from your credit card to your mortgage. You also run the risk of running the balances back up on your credit cards and not being able to make the payments.

Refinancing tip: Tidy up credit

Getting your credit history and credit score in the best possible shape will help you get a better mortgage rate. Review your credit reports and get copies of your credit scores as well. You're entitled to at least one free credit report each year from the credit bureaus, but you'll have to pay to get a copy of your credit scores.

However, the biggest risk in this scenario is in converting an unsecured debt into a secured debt. If you can't afford your credit card payments, you get nasty calls from debt collectors, a black mark on your credit report and a lower credit score.

Miss a few mortgage payments and you can lose your home to foreclosure.

On the other hand, a plain vanilla refinancing is intended to replace your existing mortgage with a new one at a lower rate. There's no cash out, unless it's to cover closing costs.

One advantage of a plain-vanilla refinancing is that it usually offers a slightly lower interest rate than a cash-out refinancing. Another major plus of this type of refinancing is that you aren't significantly increasing your outstanding mortgage debt.

That said, cash-out refinancing a mortgage can be more appropriate to accomplishing certain goals, such as paying off debt.

Managing costs

While a refinance can help you harvest more cash, it's important to watch out for costs that eat into those savings.

First, recognize that there's no such thing as a free lunch, and there's no such thing as a "no closing cost" mortgage. The originating lender will get paid for its efforts; it's just a matter of how they get paid. Closing costs can be paid in origination points, a higher interest rate or a higher loan amount.

Points come in two flavors, discount and origination. Discount points allow the borrower to prepay interest expense upfront and buy down the nominal or stated rate on the mortgage loan. The points paid are, however, considered in calculating the annual percentage rate, or APR, on the loan.

Don't forget about other expenses, such as private mortgage insurance. If your loan-to-value ratio is more than 80 percent of the appraised value of the home, the first mortgage lender will want you to pay for PMI. That adds to the cost of the refinancing.

Keep in mind that avoiding junk fees can keep down your closing costs and improve the return when refinancing a mortgage.

Bankrate wants to hear from you and encourages thoughtful and constructive comments. We ask that you stay focused on the story topic, respect other people's opinions, and avoid profanity, offensive statements, illegal contents and advertisement posts. Comments are not reviewed before they are posted. Bankrate reserves the right (but is not obligated) to edit or delete your comments. Please avoid posting private or confidential information, and also keep in mind that anything you post may be disclosed, published, transmitted or reused. We do not permit the inclusion of hyperlinks in comments and may remove any comment that includes a hyperlink.

Bankrate.com is an independent, advertising-supported publisher and comparison service. Bankrate may be compensated in exchange for featured placement of certain sponsored products and services, or your clicking on certain links posted on this website.