Facing down Iran, French president Nicolas Sarkozy stood shoulder to shoulder with President Barack Obama and British Prime Minister Gordon Brown in Pittsburgh last week. Or so it might be said. The statements of all three were consistent as they denounced the Islamic Republic's construction of a secret nuclear facility. But in this stage show of solidarity, body language sent a different message. Obama and Brown really did stand side by side. Sarkozy stood apart, looking a little like he'd been asked to stand as best man at a stranger's wedding.

Perhaps in his gut he thought this should have been his show—or at least his and Obama's. The G20 that all were attending is a forum that Sarkozy pushed to create last year. And Sarkozy's government has taken the lead in confronting Iran over its nuclear intentions.

Sarkozy wants to lead: he made it clear last year he didn't want to step down from the European presidency when his six-month term was over. Sarkozy wants to act: he's shown that in such faraway venues as the Gulf of Aden, where French troops were the first to stop payments to, and start shooting at, Somali pirates. And Sarkozy can claim, with some justification, that where he has led, Obama has followed.

Since Sarkozy became president in the summer of 2007, a year and a half before Obama took the oath of office, he has been out in front of the United States on issues ranging from Somali pirates, Iran, and the G20, to Cash for Clunkers, a carbon tax, the "Afghanization" of the Afghan war, coping with Russian belligerence, and opening the door to peace with Syria. His style is to be everywhere at once and all the time—the hyperprésident, as the French press calls him—and in that, too, Obama sometimes seems to be following his lead.

But he's not. In fact, relations between the two leaders have been far from ideal or always effective. It's sometimes unclear if Obama even notices his hyperkinetic counterpart. And that explains the ambitious Parisian's Obama obsession. Few people outside France expect the leader of the world's fifth-largest economy to set the global pace on major issues. But Sarkozy, sometimes known as l'Américain at home, has often tried to do just that. Under him the Paris-Washington partnership has become in many ways the most dynamic bilateral relationship in the Atlantic alliance, and one that helps set the global agenda. As their speeches at the United Nations and the G20 last week made clear, both he and Obama are committed internationalists with a similar vision of the new, more just and regulated world economic order. But—and this is part of the problem—both also expect to be at the forefront of any initiative: Obama because he is president of the United States, and Sarkozy because he's so ambitious, and the French are so ambitious for their president.

The question that haunts Sarkozy is whether anyone sees him as part of a globe-beating tandem—and whether this team will ever achieve its potential. The two presidents' very different personalities can collide: Obama, smiling but aloof, treats Sarkozy as one of many not-quite-equals in Europe, while Sarkozy, the backslapper, likes to call the U.S. president his "buddy," but hasn't had the favor returned. Watching the two of them onstage together, as when they appeared at D-Day anniversary commemorations in Normandy in June, is like watching the diminutive tough-guy actor Joe Pesci—all twitches and attitude—playing against Denzel Washington, all dignity and reserve. When Obama decided not to hang around for a family photo op with Sarkozy, the Élysée's fury at the perceived slight was a sensation in the Paris press.

Sarkozy's Obama complex is now a subject of persistent media speculation in France—and could become a real problem if the Obama administration doesn't make more of an effort to understand it. This isn't just a matter of policies and personalities, but of politics. In France's troubled banlieues, many young people of African and Arab origin who once sported Che T shirts now wear Obama's image instead. A recent Transatlantic Trends poll shows that Obama has a phenomenal 88 percent approval rating in France, while Sarkozy generally scores under 50. As some French journalists cautioned the new U.S. ambassador to France recently in a private meeting, if Sarkozy ever fears that the American president might try to bypass him and appeal directly to the French people on important issues, then Sarkozy's testy friendship could turn to bitter enmity.

Last week, TV interviewer David Pujadas dared to ask Sarkozy directly whether there was a "competition for leadership" between him and Obama. "There's no competition," insisted Sarkozy, hardly concealing his chagrin. "I know my place. I preside over a big country. He is president of the No. 1 economic force in the world." Citing the oft-forgotten history of "friendly ties" between the two nations, Sarkozy declared that "we have an interest in having Mr. Obama succeed." But he took pains to say that he wouldn't hesitate to cross swords with Obama on some issues, like commerce—citing his efforts to close a lucrative deal to sell advanced fighter aircraft to Brazil. While Obama had reportedly lobbied Brazilian President Luiz Inácio Lula da Silva over the phone on behalf of the Boeing F-18, Sarkozy had gone to Brasília himself to seal (some might say steal) the deal for the French-European Rafale.

Clearly this is not the kind of sympathique partnership that British Prime Minister Margaret Thatcher enjoyed with President Ronald Reagan. But Sarkozy clearly wishes it were. And no wonder. The problem isn't ideological. Both Sarkozy and Obama are realists headed toward the same pragmatic center on many global issues. They may differ on specific questions, like whether to put a ceiling on bonuses for financial executives, but they agree on basic matters, like the need to create a better global financial regulatory system.

Both men campaigned with slogans about a fundamental break with the past (which was quite a feat for Sarkozy, who had served in the previous government). And once elected, both seemed to try to change everything at once. Sarkozy pushed for a radical rethinking of environmental policies; so, too, Obama. Sarkozy instituted a highly successful program to buy up old cars and subsidize the purchase of new, more ecofriendly ones. So, too, Obama. Sarkozy put the Middle East at the center of his foreign-policy initiatives, opening up to Syria and focusing on Iran's nuclear threat. So did Obama. Only Sarkozy did all that before Obama had even taken his oath of office.

Sarkozy, always a showoff, was also much more blunt about a strategy that can come across as manic. In January 2008, when he had spent eight months in office (as Obama has now) and was facing criticism for taking on too many projects and delivering on too few, he told reporters, "You can't hope to get results unless you change everything at the same time." To do otherwise is to let the forces opposed to change gang up on you, he said, and then everything grinds to a halt. "The French ought to know this: I have a passion for action and I want to act," he announced. Obama, by contrast, has never invoked the I word—it's always about what's practical.

Such differences in style risk having a further impact on substance. Take Afghanistan. Under Sarkozy, France rejoined the integrated command structure of NATO this year, and responded to the Bush administration's pleas for more allied troops in Afghanistan by raising France's contingent to almost 3,000. But the way Sarkozy calls attention to these changes again and again in public suggests he feels he hasn't gotten enough credit for them. Now Obama wants still more from his allies. But an embittered, underappreciated Sarkozy might be tempted not to cooperate.

Such differences would be easier to smooth over if the two leaders shared the kind of full trust that the French call complicité. They don't. The U.S. president is a tough politician from the Chicago school, but not quite tough enough for the Frenchman. Sarkozy has managed to co-opt or crush virtually all opposition. (He's even had his most bitter Gaullist rival, former prime minister Dominique de Villepin, put on trial for an alleged smear campaign against him.) Obama's inability to do something similar and bulldoze his opponents in order to push through his own agenda appears to have frustrated Sarkozy. Obama is "courageous" and "understands what is at stake," Sarkozy told an interviewer last week, "but he is out in front of his country." This past spring, Sarkozy reportedly told a group of parliamentarians having lunch at the Élysée that Obama "has never run a ministry in his life," and "he's not always up to the decision making and effectiveness."

All the more pity, then, that the two men aren't closer. For when the partnership works, it brings some striking results, as Sarkozy marshals not only France's resources, but Europe's. A good example is Somalia. Last winter, multiple multinational flotillas tried to cope with the rising threat to international shipping posed by pirates off the Horn of Africa. NATO proved ineffective, as did an ad hoc force the United States cobbled together out of Bahrain. The warships' commanders proved reluctant to shoot at the pirates, and seemed unsure what to do with them if they captured them. And the Kalashnikov-toting corsairs just kept upping the ante. So Sarkozy worked with the European Union to create a much more aggressive force and also forged an agreement with Kenya allowing captured pirates to be offloaded there for trial. When Somalis seized the American-crewed Maersk Alabama and took its captain hostage in April, the U.S. Navy followed the by-then well-established precedents set by the French. It kept the pirates far out at sea, and when snipers got clear shots at the hostage takers, they pulled the trigger, killing the Somalis and freeing the captain.

"Now everything is operating very smoothly," says a U.S. official who works closely with France on NATO and related issues but isn't authorized to talk about them. "Sarkozy is an activist we can work with." More than that, the implication goes, he's not somebody you want working against you.

With Tracy McNicoll in Paris