Said the Kansas senator: "My yellow brick road came just short of the White House this time."
The conservative managed to gain the support of only 1 percent of Republicans in this month's Associated Press-Ipsos poll after peaking at 3 percent in June. Fundraising reports this week showed that his campaign was struggling financially, with $94,000 available to spend.
Brownback is expected to run for Kansas governor in 2010 when his second term expires. He has said he won't run for the Senate again.
He announced his withdrawal at the Kansas Statehouse, standing with his wife, Mary, and three of his five children.
One young campaign volunteers held a sign saying, "We (heart) Sam)."
"We're out of money," said Brownback.
He had previously said he would stay in the presidential race through Iowa's first-in-the-nation presidential caucuses in January and would drop out of the field if he finished worse than fourth there. Throughout the summer, Brownback spent considerable time and money in Iowa leading up to an August straw poll.
He finished third in that event, to former Massachusetts Gov.and former Arkansas Gov. , in a blow to his candidacy.
Huckabee could stand to gain by Brownback's departure, especially among religious conservatives who share the two candidates' opposition to abortion and gay marriage.
Before dropping out, Brownback made one last speech Friday morning at the Family Research Council's Values Voter Summit in Washington.
CBSNews.com's David Miller reports from the event in Horserace, saying the crowd, after all, was the one Brownback hoped would lift his presidential campaign off the ground, despite him being a prairie state senator with a narrow national profile. That plan didn't work out as he had hoped, but Brownback apparently didn't want to back out on the evangelical voters who have comprised the core of his limited support. (read more)
His speech contained no references to his presidential run, and none to his expected withdrawal. But it contained plenty of red meat for a conservative Christian audience. "The separation of church and state does not mean the removal of faith from the public square," he said to applause. "Any country that's walked away from God has walked away from its future."
Brownback, 51, is a former Kansas agriculture secretary who won a seat in the U.S. House in 1994, the same year voters angry with Democratic President Clinton swept the GOP back into congressional majorities.
Two years later, Senate Majority Leader Bob Dole resigned his seat to run for president, and Brownback captured Dole's seat. He won a full term in 1998 and was re-elected easily in 2004.
He is known for his passionate opposition to abortion, gay marriage and embryonic stem cell research. But his pledge to "rebuild the family and renew the culture" didn't resonate with enough voters as he ran for president.
GOP officials said the crowded presidential field made it difficult for him to break out of the pack.
"There were too many conservatives in the race, and Huckabee took off in the straw poll and that gave him some momentum that Brownback didn't have," said Des Moines lawyer Steve Roberts, a member of the Republican National Committee.