Mike Huckabee and Barack Obama have won the Iowa caucuses - the first nominating contest of the 2008 US presidential election.
Mike Huckabee (left) and Barack Obama
Mr Huckabee won for the Republicans, defeating Mitt Romney.
At the Democratic caucuses, Mr Obama won by a clear margin, defeating John Edwards, who edged Hillary Clinton into third place.
The Iowa caucuses can give big boosts to candidates' campaigns. The next contest is on Tuesday in New Hampshire.
Turnout in Thursday's caucuses rose markedly, particularly for the Democrats, with 239,000 Democrats taking part - up from 124,000 in 2004.
Results from more than 1,780 caucuses (or public meetings) showed that Mr Huckabee, a former Arkansas governor and Baptist minister, had polled just over 34% of the vote.
Mr Romney, a former governor of Massachusetts, secured 25% support.
"Tonight what we have seen is a new day in American politics. Tonight we proved that American politics is still in the hands of people like you," Mr Huckabee told his cheering supporters.
The victory for Mr Huckabee is seen as a blow for Mr Romney, who has spent tens of millions of dollars more on his campaign.
However, Mr Romney said the battle for the nomination was far from being lost. "This is obviously a bit like a baseball game, first inning. Well, it's a 50-inning ball game. I'm going to keep on battling all the way and anticipate I get the nomination when it's all said and done," he told Fox News.
In the Democratic race, Mr Obama won 38% of the vote.
Mr Edwards and Mrs Clinton were almost level on around 30% with Mr Edwards just ahead.
"We are choosing hope over fear, we are choosing unity over division and sending a powerful message that change is coming to America," Mr Obama, who is vying to become the first black US president, told his supporters.
Mr Obama, a senator from Illinois, will now be hoping to build momentum for the rest of the race, the BBC's Kevin Connolly in Iowa says.
However, both Mr Edwards and Mrs Clinton vowed to continue the fight for the Democratic nomination.
"We have always planned to run a national campaign all the way through the early contests," said Mrs Clinton, flanked by her husband - former President Bill Clinton.
Jubilant crowds celebrated Mr Huckabee's victory at a party in a Des Moines hotel.
Among them was Mary Duggar, a volunteer who had travelled from Mr Huckabee's home state of Arkansas to help his campaign.
3 Jan: Iowa caucuses
8 Jan: New Hampshire primary
15 Jan: Michigan primary
19 Jan: Nevada caucuses; South Carolina primary (Rep)
26 Jan: South Carolina primary (Dem)
29 Jan: Florida primary
5 Feb: some 20 states including California, New York, New Jersey
"He's a fantastic candidate. I thought he would win but I didn't know it was going to be quite this good," she said.
A few blocks away, Obama supporters held their own party at Des Moines's Hyvee Hall.
"We are ecstatic," said 16-year-old Jenny Ajluni, who was too young to take part in a caucus but joined the victory rally.
Eighteen-year-old brother Chris said: "He really made history tonight."
While the Democrats' participation rose most substantially, turnout was also up on the Republican side, with some 115,000 people taking part - up from fewer than 90,000 in the last contested Republican caucuses in 2000.
Similar caucuses or primaries will take place across all American states before each party backs a single candidate to contest the November election for the White House.
Mrs Clinton said she was "confident" going into the next contest
The Iowa caucuses and the New Hampshire primary on 8 January are regarded as key for building momentum in the state-by-state process of winning the presidential nomination.
Candidates who do poorly tend to drop out of the race. Democratic veterans Chris Dodd and Joe Biden said late on Thursday they were bowing out after poor showings in Iowa.
Polls from New Hampshire indicate that the Democratic race is between Mrs Clinton and Mr Obama, while the Republican contest is between Mr Romney and Senator John McCain.
Rudy Giuliani, who has been leading the Republican national polls, did not campaign in Iowa, accepting that his political positions were unlikely to garner much support.
Instead he has been focusing on larger states, among them Florida which holds its primary on 29 January.