Economic optimism in the United States is surging, according to the latest CNBC All-America Economic Survey, with several key components hitting all-time highs, but it's not helping the president.

The CNBC survey of 800 Americans across the country finds that 30 percent of the public are optimistic about the economy now and for the future, the first time the percentage has been that high in two consecutive quarters during the survey's 10-year history.

The 54 percent of Americans who think their home prices will rise in the next year represents a record and the 44 percent who believe their wages will go up in the next year is the second highest in a decade. There's similar optimism around stocks, where 44 percent of Americans believe this is a good time to invest, a level only eclipsed by last quarter's record.

"Attitudes about [President Donald] Trump's economy at this point, remain consistent, positive and strong,'' said Micah Roberts, the Republican pollster for CNBC with Public Opinion Strategies. Jay Campbell from Hart Research was the Democratic pollster. The poll was conducted June 9-12 and has a margin of error of plus or minus 3.5 percentage points.

The positive economic attitudes aren't doing much to help the president's approval rating, which has fallen to 37 percent in the current survey from 39 percent in April. His approval on the economy has also fallen to just 41 percent from 44 percent in April. And there has been a rise in pessimism, driven by groups such as retirees, blue collar workers and independents, including some core Trump supporters.

Showing the split in the public over the impact of Trump, a quarter in the poll said the economy is getting better because of the president's policies. Meanwhile, 22 percent said his policies are making the economy worse.

Some of Trump's signature economic policies remain popular, but they have taken a hit from the prior poll. The majority still approves of Trump's plans to cut individual taxes, 59 percent to 30 percent, but that 29 point gap is 13 points smaller than in April. The president has majority support for his plans to cut business taxes, renegotiate trade deals and rebuild the nation's infrastructure, but the margin of support has slimmed in each case.

And, as in previous surveys, his immigration, climate change and health-care policies are opposed by a plurality of Americans.

Looking at specific policies, 53 percent support privatizing infrastructure to expand highways and airports, while 33 percent opposed. But when asked specifically about Trump's plans to privatize the FAA, the numbers flip, with 53 percent opposing and 33 percent in favor.

The president's decision to leave the Paris climate accord is opposed by 57 percent in the poll. And 80 percent think it's appropriate for U.S. companies to continue to try to meet the accord's goals despite the U.S. plans to pull out. And 72 percent say it will be effective for companies to do it alone without the Federal government.