In a jam-packed ceremony in the East Room that was part pep rally, the president pointed out that the last time the Yankees - winners of 27 titles - were toasted at the White House was 2001.
"It's been nine years since your last title - which must have felt like eternity for Yankee fans. I think other teams would be just fine with a spell like that. The Cubs, for example," Obama said, drawing laughs from players, coaches, members of his Cabinet and Congress and other guests. He added that his White Sox have gotten close, including a title in 2005.
The Yankees won the World Series in six games last year, defeating the Philadelphia Phillies. New York Manager Joe Girardi presented Obama with a signed Yankees' jersey with the No. 27.
The White House visit was the fifth for the Yankees core four - Derek Jeter, Mariano Rivera, Andy Pettitte and Jorge Posada - who have a handful of championship rings. They've met three presidents - Bill Clinton in the 1990s, George W. Bush in 2001 and now Obama.
Obama praised the players for their off-field work, from a scholarship that first baseman Mark Teixeira established at his high school with a $75,000 check, to catcher Posada's work on a support network for families with ailing children to shortstop Jeter's sportsmanship.
Earlier in the day, members of the team visited war wounded at Walter Reed Army Medical Center, which several players described as a sobering experience. Third baseman Alex Rodriguez, who wore his championship ring, called the servicemembers the "real heroes" and pitcher Andy Pettitte hailed their sacrifice. Pettitte said even a few Boston Red Sox fans among the wounded appreciated the Yankee visit - though they kept their Red Sox caps on.