Schroeder secured another four years for his coalition with the small Greens party in Sunday's vote, handing Europe's dwindling left another boost a week after Social Democrats triumphed in Sweden.
But he will have to tackle problems such as chronic unemployment and slow economic growth and confront strains in the country's generous welfare state with a slender majority that opponents said will not hold.
"The country remains ungovernable because it is impossible to tackle its economic problems," said Karl-Heinz Nassmacher, political scientist at Oldenburg University. "What we need is a German Margaret Thatcher but where are we going to find her?"
Official results released early Monday showed the Social Democrats and Greens won a combined 47.1 percent of the vote for the lower house, or Bundestag. Opposition parties led by resurgent conservatives under Edmund Stoiber totaled 45.9 percent.
That gave the Social Democrats and Greens 306 seats in the new 603-seat parliament, compared to 295 for conservatives and the pro-business Free Democrats. Reformed communists won the other two seats.
A jubilant Schroeder appeared arm-in-arm with Foreign Minister Joschka Fischer of the Greens before cheering supporters in Berlin.
"We have hard times in front of us and we're going to make it together," Schroeder shouted.
Schroeder said he would immediately start coalition talks with the resurgent Greens, who saved his government with their strong showing in the election while his Social Democrats (SPD) fell.
"Those who think that there will be large difficulties are wrong," Schroeder told reporters as he entered SPD party headquarters for a meeting of party leaders.
The Greens were exuberant after their best showing in their 22-year history — 8.6 percent. But Fischer declined to say whether the Greens would demand another ministerial position.
"One must be modest in victory," he said.
Chastened by his narrow defeat, conservative challenger Stoiber said Schroeder would face a reinvigorated opposition and forecast that his power base would prove brittle.
"I predict that this Schroeder government will rule for only a very short time," Stoiber said.
Schroeder's coalition has a nine-seat majority in the new parliament, down from a 21-vote advantage in his first term. The winning margin is tighter than in 1976, previously the closest race, when a Social Democrat-led government won a 10-seat majority.
Schroeder's outspoken opposition to a military conflict with Iraq was credited with giving him a late push in a tight campaign. But it sparked a rare open spat with the United States and accusations he whipped up emotions against a vital ally for electoral gain.
"What I criticize above all is that (Schroeder) opened the floodgates for anti-American tones," Stoiber said on German television, calling the crisis with the United States "the most devastating of the last 50 years."
Analysts expect Schroeder to adopt a softer tone after the election, but he showed no intention Monday of backing down. He has insisted he would not commit troops for a war even if the United Nations backs military action.
"I have formulated a German position, and I have nothing to retract on that count," Schroeder told German television.
The rhetoric reached a damaging peak in the final days of his campaign when Justice Minister Herta Daeubler-Gmelin was reported to have compared President George W. Bush to Hitler for threatening war to distract from domestic problems. She denied saying it.
The Social Democrats said she would not have a post in a new government, although she will be in parliament.
The Bush administration has reacted coolly to Schroeder's moves to repair the damage, including a letter to the president, but others in Washington were optimistic the frayed relationship could be mended.
Speaking on CNN Sunday, Democratic Sen. Joe Biden, chairman of the Senate Foreign Relations Committee, said the "core relationship between the Republic of Germany and the United States is solid. What you had is Schroeder doing what a lot of politicians do, trying to get out his base."
Schroeder may have won, but his failure to deliver on a promise to reduce unemployment eroded support for the Social Democrats, which slid 2.4 percentage points from 1998's 40.9 percent result.
Stoiber's platform focused on the economy boosted the conservatives to 38.5 percent, up from 35 percent four years ago. The results indicate they have put behind them a campaign financing scandal that had engulfed the Christian Democrats and their former leader, Helmut Kohl.
But prospects for a conservative coalition were hurt by a scandal in the Free Democratic Party over deputy leader Juergen Moellemann's renewed attacks on a prominent German Jewish leader. The party's leadership demanded his resignation.
Some 79 percent of Germany's 61 million voters turned out Sunday -casting two votes, one for a local candidate and one for a party. The party vote determined the percentage of seats each party won in the Bundestag, or parliament, chosen from a list of candidates submitted.
Beyond his forthright stand on Iraq, Schroeder broad-brushed much of his agenda for a second term except to uphold values like a fair society and the welfare state.
Stung by Germany's jobless problem, he has pledged to reform the highly regulated labor market. He has also promised to expand all-day schools and child care to make life easier for working mothers.