Americans voted for change over experience as Barack Obama and Mike Huckabee won the Iowa caucuses.
Illinois senator Mr Obama, who would be the first African American US president, and former Baptist preacher Mr Huckabee will now have five days before the world’s focus shifts to the New Hampshire primary on Tuesday.
The winners in both the Democrat and Republican contests said change was coming to America and hailed a new day in US politics.
Democrat Mr Obama told his supporters: “You came together as Democrats, Republicans and Independents to stand up and say: ’We are one nation; we are one people; and our time for change has come’.”
To chants of “Obama” and “USA, USA” from the crowd, Mr Obama said: “They said this day would never come. They said our sights were set too high. They said this country was too divided, too disillusioned to ever come together around a common purpose.
“But on this January night, on this defining moment in history, you have done what the cynics said we couldn’t do - you have done what the state of New Hampshire can do in five days. You have done what America can do in this new year, 2008.”
He said Americans were “choosing hope over fear…unity over division, and sending the powerful message that change is coming to America”.
He said that in the future Americans would be able to look back on the night of the Iowa caucuses with pride and say: “This was the moment when it all began. This was the moment, this was the place where America remembered what it means to hope.
“Something better awaits us if we have the courage to reach for it, to work for it, and to hope for it.”
“In the face of impossible odds, people who love this country can change it,” he added.
“In New Hampshire, if you give me that same chance that Iowa did, I will be that president for America.”
He went on: “We are a collection of red states and blue states; we are the United States. In this moment, in this election, we are ready to believe again.”
Hillary Clinton will now hope to get her campaign back on track in New Hampshire next week, while a victory for Mr Edwards in Iowa was seen as crucial if his campaign was going to gain momentum.
With former President Bill Clinton at her side, Mrs Clinton told supporters at her Iowa campaign headquarters that American Democrats needed to nominate a candidate “who will go the distance and who will be ready to lead on day one”.
“I am ready for that contest,” she said. “We’re not just trying to elect a president, we’re trying to change a country. That is what I’m committed to doing.”
Mrs Clinton said: “Today we’re sending a clear message. We are going to have change and that change will be a Democratic president in the White House in 2009.”
Mrs Clinton added: “I am so ready for the rest of this campaign, and I am so ready to lead. We have a long way to go, but I am confident and optimistic – both about the campaign and our country.
“I know we’re going to get up tomorrow and keep pushing as hard as we can.”
Mr Edwards said the results showed “change won and the status quo lost”.
He added he would continue running as the candidate for middle-class Americans.
“I’m going to fight for that change,” he said. “I’ve fought for it my entire life. I have a long history of fighting powerful interests and winning.”
He went on: “What’s clear from the Iowa caucus results is that change won and the status quo lost…The fight is now to see if we are going to get the change we need to save the middle class in this country.”
While the Democratic race was always close, Republican Mr Huckabee continued his strong surprise surge.
The 52-year-old former Arkansas governor said his victory signalled “a new day in American politics”.
Surrounded by supporters, including his wife Janet, his three children and the actor Chuck Norris, Mr Huckabee said: “It’s a celebration for everybody on our team. I’m amazed and I’m encouraged. Today what we have seen is a new day in American politics. A new day is needed in American politics.
“It starts here, but it doesn’t end here.”
Mr Huckabee, who was outspent 15-to-1 by Mr Romney, said it would end at the White House and added that the results showed that “people really are more important than the purse”.
“It’s not about who raised the most money,” he said.
“It’s about who raised the greatest hopes, dreams and aspirations for our children and their future.”
He went on: “This election is not about me, it’s about we. What is happening tonight in Iowa is going to start really a prairie fire of new hope and zeal, and it’s already happening.”
His closest rival, former Massachusetts governor Mr Romney – whose Mormon faith has caused concerns among some Republicans – insisted he was in the race for the long haul.
He said his campaign had “come a long way” in the last year, and that they would go on to win the race.
The Republican national front-runner, former New York mayor Rudy Giuliani, has run a very limited campaign in Iowa, choosing to concentrate on states which go to the polls later.
With all of the results from the Democrat contest in, Mr Obama won with 37.58% of the votes. Mr Edwards came second with 29.75%, closely followed by Mrs Clinton in third place with 29.47%.
New Mexico governor Bill Richardson had 2.11%, Delaware senator Joe Biden had 0.93% and Connecticut senator Chris Dodd had 0.02%
With 85% of the Republican caucus results in, Mr Huckabee had 34%, Mr Romney 25%, and both actor and former senator Fred Thompson and former prisoner of war John McCain had 13%.
Congressman Ron Paul had 10%, Mr Giuliani 4% and congressman Duncan Hunter 1%.