MIAMI – Florida’s Lee County has sold $81.2 million of bonds to keep an attraction that generates $21 million a year in tourism: the Boston Red Sox.

The debt sold Wednesday will finance a new stadium for the club in Fort Myers, 120 miles south of Tampa on the west coast of Florida. The securities are backed by a tax on overnight lodging and by lease payments from the Red Sox and the Minnesota Twins, which train at another stadium in the county.

The Red Sox will move from an older county-owned stadium without penalty. Fort Myers will remain responsible for $17.5 million of bonds outstanding on the previous ballpark, said Maria Joyner, the city’s director of finance.

“The Red Sox wanted a comprehensive training complex,” said Jim Lavender, director of the Lee County Public Works Department. “The board wanted to keep them in town.”

The team has wintered in Fort Myers since 1993, using a stadium separate from its practice fields. It was in talks with Sarasota, 70 miles north, about moving to a new facility with adjacent practice fields before Lee County Commissioners approved borrowing to keep the franchise.

While the Red Sox “kicked the tires” of a couple of Florida communities in addition to Sarasota, they are “excited about continuing an existing partnership with Lee County for a long time to come,” said Jonathan Gilula, the team’s executive vice president of business affairs.

The Red Sox, owned by John W. Henry, a commodities hedge- fund billionaire, were third in the American League Eastern Division as of Wednesday, nine games behind the New York Yankees, and in second place in the AL wildcard standings, 6 1/2 games behind the Tampa Bay Rays. Boston last won the World Series in 2007.

Other baseball franchises have abandoned their spring- training facilities. The Los Angeles Dodgers left Vero Beach, Fla., in 2009 for Glendale, Ariz. Indian River County, on Florida’s east coast, still owes $12.3 million for the Dodgertown facility, said budget director Jason Brown.

The Pima County Stadium District in Arizona lost the Chicago White Sox in 2009 and the Arizona Diamondbacks have said they’re leaving next season. The district has about $21 million of outstanding debt on the Kino Sports Complex, where both teams played, according to the county’s 2011 budget.

The White Sox were able to break their lease by paying $5 million, said Chris Bartos, director of the stadium district. The Red Sox have a 30-year lease at their new stadium, which will be ready in 2012, and the county would be able to ask a court to prevent the team from leaving and seek damages, said County Attorney David Owen.

Negotiations to break leases are common, said Richard Karcher, director of the Center for Law and Sports at the Florida Coastal School of Law in Jacksonville.

“Money talks,” he said. “The alternative is you have a party that doesn’t want to be there anymore.”

The monthlong spring training for the Grapefruit League in Florida, before the regular season begins in April, generated $752.3 million in economic activity for the state in 2009, according to a study for the Florida Sports Foundation.

The Cactus League in Arizona estimates its spring training boosted the state’s economy by $350 million in 2009. In 2010, for the first time, the Cactus League and Grapefruit League had the same number of teams at 15 each after the Cincinnati Reds moved from Sarasota to Goodyear, Arizona.

The Red Sox brought about $21 million in spending to Lee County from people who visit primarily to attend games, according to a 2009 study for the Visitor and Convention Bureau. The Minnesota Twins added $20 million, the study said. The county’s tourism industry has an economic impact of $3 billion, according to the bureau.

It’s money Lee County can’t afford to lose. The county estimated it would need to use $60 million of general-fund reserves in fiscal 2010 to meet expenses. Assessed property values are projected to decline more than 40 percent from 2009 to 2011, according to Moody’s Investors Service. Unemployment in August was 13.7 percent, Florida’s labor department said, higher than the state average of 11.7 percent and the national level of 9.6 percent.

While building stadiums can provide some economic stimulus, they’re unlikely to have the lasting effects of other construction projects, such as roads, schools or bridges, said Dennis Coates, professor of sports economics at the University of Maryland in Baltimore.

“There are better ways to spend public money than on building a spring-training facility,” he said.