Federer joins Pete Sampras, Jimmy Connors, John McEnroe and Ivan Lendl as the only men's players to end the season ranked No. 1 four or more times since the inception of the ATP rankings in 1973.
Federer, who had failed to win his home tournament six consecutive times before winning last year, captured a tour-high seventh title of the season.
"It's always emotional at the end," Federer said. "I remember being here as a ball boy myself. I know 50 percent of the people working at the tournament.
"It's nice to win again and go into the next year as No. 1 again," said Federer, who won three Grand Slam titles this year and has 12 overall, two fewer than the record 14 won by Sampras.
Federer broke on a forehand error by Nieminen to lead 2-0, and he closed out the first set with a volley in 27 minutes.
|Roger Federer wins his seventh tournament of the year. (Getty Images)|
But Nieminen served a double-fault in the next game to face a break point, then put a forehand wide to give Federer a decisive 5-4 lead. When Nieminen's return went long, Federer held a match point and closed it out with a backhand volley winner.
Nieminen fell to 0-8 against Federer.
After losing the Madrid Masters final to David Nalbandian last week, Federer dropped a set in his opening match in Basel before winning the next four in straight sets. He is now 7-4 in finals this year and has 52 career titles.
"I had a great week," said Nieminen, who became the first Finn to win an ATP title in 2006 in Auckland. "I was trying too much at the start of the match. I tried to hit too many winners. I started to play better in the second but it wasn't good enough. I had too many unforced errors. Roger is tough when it gets tight."