Baby boomers may have provided the bulk of the productivity surge in this country during the past couple of decades, but now they're retiring in unprecedented numbers. This is setting in motion a number of interesting scenarios.

Some retirees are still recovering from the Great Recession swoon. Many are concerned about the Social Security funding gap, and some need their nest eggs to stretch further because people are living longer than ever these days.

But for all retirees, choosing where to retire can be just as important as choosing when to retire.

Source: Flickr user Moodboard.

The five best states for senior citizens to retire in
As we saw last weekend, more than a dozen U.S. states tax Social Security income either at the federal rate or at rates based on their own formulas. In addition, sales tax, property tax, and a bevy of other costs can vary throughout the country. Thus some states let senior citizens hang on to more of their hard-earned cash than others do.

Thankfully, Bankrate has done the hard work for us. By using a number of factors that include tax burden, cost of living, access to healthcare, crime rate, and even weather, it has ranked the top states for senior citizens to retire in. According to Bankrate's findings, here are the five best states for retirement, in ascending order:

Grand Teton National Park, Wyoming. Source: Dawn Ellner via Flickr.

5. Wyoming
For those who are keen on big tax savings Wyoming is a state that's likely been on your radar for a long time. Some of the prime advantages of living out your golden years in Wyoming include no estate or inheritance tax, no state income tax, and a minuscule 4% state sales tax. In addition, according to the Tax Foundation, the state's property tax rate averages less than 0.6% of median property values, and its average combined state and local tax burden of 5.34% is good enough to rank eighth-lowest in the country.

"Why the low taxes," you ask? Wyoming sits on a hotbed of oil and gas shale deposits, so its asset-rich lands have provided ample benefits for retirees within the state. As an added bonus, Bankrate notes that the crime rate is also relatively low. 

J. Nelson Kelly House in Grand Forks, N.D. Source: Wikimedia Commons user Glorioussandwich.

4. North Dakota
Retirees in North Dakota have to fork over a bit more tax money than Wyoming retirees. North Dakota residents are subject to Social Security taxation up to the extent that it's taxed on a federal level, and they're also fully taxed on private pensions. As for state and local taxes, North Dakota's are below the national average of 9.8%. North Dakota's income tax rate varies between 1.51% and 3.99%, while its sales tax rate is a flat 5%.

So what makes North Dakota so attractive for retirees? Aside from a low cost of living -- once again stemming from oil and gas finds in the state -- Bankrate said the main draw is the fact that its residents appear to be the happiest and healthiest in the nation.

The measurement used here was the Gallup-Healthways Well-Being Index, which surveys 500 people per day in an effort to determine their perceived "well-being" based on a number of factors, including their emotional, physical, and financial health. The latest Well-Being Index in 2013 ranked North Dakota as No. 1 in the country in terms of "physical health" and "work environment," No. 2 in "emotional health," and No. 4 in "life evaluation." Enjoying retirement isn't just about money, but rather overall happiness -- and this annual survey suggests that North Dakotans are a pretty happy bunch.  

Arch stones in Utah. Source: Pixabay user LoggaWiggler

3. Utah
The reason retirees may want to choose Utah as a top retirement destination is that it offers a blend of some of the points we've touched upon already.

Although Utah does tax Social Security income, for example, it affords its residents the opportunity to claim a retirement tax credit depending on a number of factors, including their age and their annual income (the credit phases out at $25,000 for an individual filer). In other words, there are ways of being exempt from Social Security taxation in Utah. 

Utah also has some of the most affordable housing relative to the income of its residents. In late 2012, the National Association of Home Builders/Wells Fargo Housing Opportunity Index singled out Ogden, Utah as No. 1 in the country in terms of housing affordability. Presumably, things have changed a bit since this NAHB report was issued, but Utah remains a prime destination for retirees who are looking to stretch their dollar when buying a home. 

Source: Pixabay user Simplyelke.

2. Colorado
Similar to Utah, Colorado has a bit of everything to offer to retirees. Colorado has no estate or inheritance tax, it offers an easy-to-understand flat-tax of 4.63%, and median property taxes are fairly low, with the Tax Foundation noting that the median homeowner paid just $1,437 in property taxes on a home worth $237,800. To add some context, in 2012 the average U.S. homeowner forked over $2,800 in property taxes. 

But Colorado isn't perfect, as some retirees will need to pay tax on Social Security income. For instance, Colorado residents aged 55 to 64 are allowed to exclude up to $20,000 in Social Security and retirement income from state taxes. For those aged 65 and up, that exclusion jumps to $24,000. Of course, if you're making more than the exclusionary amount, prepare to open up your wallet.

On top of its generally favorable tax rates, Colorado also scored in the top seven in the Gallup-Healthways Well-Being Index for "life evaluation," "healthy behaviors," and "physical health."

Mount Rushmore, S.D. Source: Pixabay user Werner22brigitte.

1. South Dakota
Notice a trend of where these five states are located?

Tying together everything we've learned about the four aforementioned states, the draw of South Dakota is a mix of exceptionally low tax rates and high ranks on the Gallup-Healthways Well-Being Index.

Specifically, South Dakota is one of only seven states in the country that have no income tax. Add in a state sales tax of just 4% and municipality tax rates that are typically 2% or less, and you can begin to see how retirees can save a pretty penny in the home of Mount Rushmore. As with a number of other states in the region, South Dakota's vast energy assets allow the state to skip on collecting an income tax, as the energy boom is generating more than enough revenue.

In terms of well-being, South Dakota ranked No. 2 in the country behind only North Dakota. South Dakota finished second in "work environment," third in "emotional health," fifth in "basic access" to medical care, and eighth in "life evaluation."