For a long time, a lot of American companies saw China as the world's biggest business opportunity. But that time may be over.
This week, McDonald's was reportedly in talks to sell its China unit and license its name to a Chinese company instead, following Yum Brands' decision to do something similar and spin off its China operations into a new firm called Yum China last month.
"The trend is that opening retail business on the ground in China as a foreigner is difficult and expensive," said Dan Harris, lawyer at Harris Bricken and author of the China Law Blog.
"We have for years tried to push a lot of our clients not to do that, but instead do what McDonald's and Yum Brands are doing, which is … monetize your name and your knowledge without actually being the one who does all the work to make it work in China," Harris said. "China is a tough, tough market."
McDonald's said in March it was looking for "strategic partners" for key Asia markets. Last year, Yum Brands said its decision to spin off its China unit followed a "rigorous review of strategic options."
Fast food companies were early major entrants to China nearly three decades ago. As individual Chinese grew wealthier, the opportunities for tapping the Chinese consumer market appeared to grow exponentially. But roadblocks appeared: U.S. fast food chains struggled with food safety scandals in China, and other companies have had intellectual property such as trademarks stolen.
"We have seen a lot of U.S companies struggling [with] their China" operations, said Siva Yam, president of the Chicago-based U.S.-China Chamber of Commerce. "The market is much more mature. We have seen a significant drop of U.S. companies going to China. … On the contrary, they are coming back here."
An annual report from the American Chamber of Commerce in China found last year that 32 percent of member companies surveyed do not plan to expand investments in China, a percentage that's higher than during the financial crisis in 2009.
One-quarter of the respondents have moved or plan to move business operations out of China, and of that group, 38 percent are relocating to the U.S., Canada or Mexico, according to the survey, published in January.
While Chinese firms have often had the advantage of local business know-how or government support in China, rising labor and land costs increased challenges for foreign companies further, analysts said. China's economic growth is also slowing, from double-digits a few years ago to just above 6 percent officially.
Starbucks is a notable exception. At an investor conference Wednesday, the coffee chain's management said it expects to open more than 5,000 stores in China by 2021 and that the market "will eclipse that in the U.S. over time."
U.S. farmers also continue to do well in China, especially when exporting crops such as soybeans. Agriculture is one of the few areas in which the United States has a trade surplus with China, or exports more than it imports.
Commodities-sensitive U.S. firms such as Caterpillar invested heavily in China in an attempt to ride the economic boom there. Consumer-oriented companies like Apple followed, trying to target Chinese consumers.
Copper prices, often seen as an indicator of China's industrial health, are down more than 40 percent from a 2011 peak, and Caterpillar is on track for its first four-year decline in sales and revenues. And since the fiscal second quarter of this year, Apple has reported year-over-year declines of more than 25 percent in Greater China sales, versus double-digit growth previously.
"If you're waiting for the booming Chinese consumer ... it's just not on the way. The upside is just not what some consumer firms were hoping for," said Derek Scissors, chief economist at China Beige Book International, which regularly surveys Chinese businesses.
China is also maturing as an economy. The country boasts many iPhone rivals, the world's biggest drone maker and strong, homegrown e-commerce market.
"Chinese business people and Chinese businesses have a lot of money, and they can afford to buy" major U.S. companies' Chinese units, said Geoffrey Sant, partner in the trial department of Dorsey & Whitney and a former professor of U.S. law in Beijing. China has long required most U.S. firms to partner with Chinese counterparts in order to do business there in the first place.
"I wouldn't necessarily categorize these sales as 'I'm wanting to get out of China,' but more as 'I'm willing to buy' [for] a lot of cash," he said.
Now U.S. firms may need to try a different China strategy in order to thrive there.
"I do think there are new firms that are finding China as interesting as everyone used to," Scissors said. He pointed to opportunities in senior care, environmental protection and asset management, especially as China copes with massive levels of domestic debt.
Another possible opportunity may lie in financial services. In the last few months, fund management firm Vanguard and JPMorgan Asset Management both received approval to establish wholly owned subsidiaries in Shanghai.
"We see this as the first step of our mission to lower the cost of investing in China and help millions of local investors reach their goals," Vanguard spokeswoman Linda Wolohan said in an emailed statement.
— CNBC's Jane Wells contributed to this report.