With just over 10 weeks before nationwide elections that could define the remainder of Obama's first term, only 38 percent say they support his expanded war effort in Afghanistan - a drop from 46 percent in March. Just 19 percent expect the situation to improve during the next year, while 29 percent think it will get worse. Some 49 percent think it will remain the same.
The numbers could be ominous for the president and his Democratic Party, already feeling the heat for high unemployment, a slow economic recovery and a $1.3 trillion federal deficit. Strong dissent - 58 percent oppose the war - could depress Democratic turnout when the party desperately needs to energize its supporters for midterm congressional elections.
Afghanistan: The Road Ahead
On the Afghan Frontlines with Gen. Petraeus
Petraeus Talks about Challenges in Iraq
Afghanistan's Most Dangerous Job: Finding IEDs
Ahmed Karzai: No Proof in Criminal Accusations
A majority of Americans do welcome Obama's decision to end combat operations in Iraq. Some 68 percent approve, a number unchanged from earlier this year. The last American combat brigade began leaving Iraq on Thursday, ahead of Obama's Aug. 31 deadline for ending the U.S. combat role there.
Seven years after that conflict began, 65 percent oppose the war in Iraq and just 31 percent favor it.
The growing frustration with the Afghanistan war was evident in Massachusetts' 5th Congressional District, not far from Concord where Minutemen fought for a new nation in 1775. In Lawrence, whose textile mills once relied on the roaring Merrimack River, exasperation with the war in Afghanistan is evident.
"If they could resolve the issue, stabilize the government, that would be good. But we can't do this forever and lose more lives," said Terry Landers, 53, an electrician from North Andover.
U.S. troops have suffered more than 1,100 deaths in Afghanistan since fighting began in October 2001, including a monthly record of 66 in July. Last fall, Obama authorized an increase in the force in Afghanistan by 30,000 to 100,000 troops - triple the level from 2008. Many in Congress are increasingly doubtful that the military effort can succeed without a tough campaign against bribery and graft that have eroded the Afghan people's trust in their government.
Video from Afghanistan: the Road Ahead:
Opinions in the poll - and among those interviewed - were more positive about Iraq as Obama's deadline for the exit of U.S. combat forces approached.
"I think we really need to give them an opportunity to economically, socially grow," said Mary Campbell, 56, a Lawrence city worker. "I think it's more helpful if we're not in their face all the time, so the deadline is, I think, a good thing, to see how stable they are."
The congressional seat is held by Rep. Niki Tsongas, a Democrat who is the widow of a former senator and one of the party's 1992 presidential contenders, Paul Tsongas. Four Republicans and one independent are seeking to oust her in November, with the primary next month.
Lawrence has lost two sons in Iraq of the more than 4,400 Americans killed since fighting began in March 2003. Obama ran for president in part on a pledge to pull out of Iraq and divert U.S. resources to Afghanistan, and that shift has been accompanied by a changing death toll in each country.
The war views expressed in a Lawrence diner, in a park across from City Hall and at an Essex Street hot dog cart, were echoed by poll participants across the country.
Bea Boynton, 57, of Marysville, Pa., said she is less supportive of the wars than when Obama took office.
"I just think it's not going well. Too many of our men and women are being killed," she said of Afghanistan in particular.
Boynton, a registered Democrat who voted for Republican John McCain in 2008, added: "I don't think what we initially set out to do has been done. I mean, we still don't have (Osama) bin Laden."
Erika Hickert, 68, a retired school teacher in Maricopa, Ariz., said she is an independent who voted for Obama in 2008 and would do so again if given the chance. She felt the same about the wars.
"I'm just tired of taking care of the world," Hickert said. "They need to learn to take care of themselves, and war isn't the way to teach them."
She also doesn't distinguish between Iraq and Afghanistan, even with the conflict winding down in one while ramping up in the other.
"I think of them as one big conflict," said Hickert. "We're militarily supporting both of them."
Landers, the electrician, was among those with split opinions about Afghanistan in particular.
A registered Republican who voted for McCain, Landers said he did not favor pulling out of Afghanistan despite his concern about the mounting death toll and his opposition to a long-term combat role.
"I think we need to get the government stabilized before we get out of there. I don't know how we can do that, though," he said.
Campbell, the city worker, is a Democrat who voted for Obama. She has a son-in-law in the Marine Reserves who has already made one tour of Iraq and is slated to head back to the Middle East next year.
"I think it's important that, as citizen of the United States, where we live in a free country ... that we help support the mission of bringing along peace," she said.
Another poll respondent, Jeff Foust, 60, a retired public defender in Springfield, Ill., was more sanguine.
"All we can do is continue to provide some support but I think that we can't stay in either country for a long term with large numbers of troops," said Foust, a Democrat who voted for Obama in 2008 and said he would again. "We've been there long enough in both places that winning is up to the people that live there."
The AP-GfK Poll was conducted August 11-16 by GfK Roper Public Affairs and Corporate Communications. It involved landline and cell phone interviews with 1,007 adults nationwide, and has a margin of sampling error of plus or minus 4.5 percentage points.
By Associated Press Writer Glen Johnson. Polling Director Trevor Tompson, AP News Survey Specialist Dennis Junius and AP writers Lauren Sausser and Ileana Morales in Washington contributed to this report