In early 2010, somewhere high above the northern hemisphere, Mark Krywko decided he’d had enough. The CEO of Sleek Audio, a purveyor of high-end earphones, Krywko was flying home to Florida after yet another frustrating visit to Dongguan, China, where a contract factory assembled the majority of his company’s products. He and his son, Jason, Sleek Audio’s cofounder, made the long trip every few months to troubleshoot quality flaws. Every time the Krywkos visited Dongguan, their Chinese partners assured them everything was under control. Those promises almost always proved empty.

As he whiled away the airborne hours, Krywko made a mental list of all the manufacturing glitches that had nearly wrecked his company. There was the entire shipment of 10,000 earphones that Sleek Audio had to discard because they were improperly welded, a mistake that cost the company millions. Then there were the delivery delays caused by the factory’s lackadaisical approach to deadlines, which forced the Krywkos to spend a fortune air-freighting products to the US. Even when orders were produced on schedule, Krywko wasn’t too pleased with the situation: The company always had precious cash tied up in inventory that took months to arrive after the prototypes had been approved.

One reason for abandoning China is quality: Some products are too flawed to sell.

The headaches had finally become too exasperating to bear. And so, on that flight, he turned to Jason and said that he was done with Dongguan. “I can’t do it anymore,” he said. “Let’s bring it home.”

Jason had been thinking the same thing.

When the Krywkos returned to the US, they searched for a manufacturing partner with the tools and expertise to produce their earphones. They found one just a few miles away from their Palmetto, Florida, headquarters: Dynamic Innovations, a maker of ruggedized computers and other equipment. Sleek Audio quickly signed up.

Today, a year since Krywko’s decision to go against the offshoring tide, Sleek Audio has a full-scale manufacturing operation that can be reached via a 15-minute car ride rather than a 24-hour flight. Each earphone costs roughly 50 percent more to produce in Florida than in China. But Krywko is more than happy to pay the premium to know that botched orders and shipping delays won’t ruin his company. And so far, the gambit appears to be paying off: Based on enthusiastic customer response, Sleek Audio is now projecting 2011 to be its most profitable year ever.

For US firms, the decision to manufacture overseas has long seemed a no-brainer. Labor costs in China and other developing nations have been so cheap that as recently as two or three years ago, anyone who refused to offshore was viewed as a dinosaur, certain to go extinct as bolder companies built the future in Asia. But stamping out products in Guangdong Province is no longer the bargain it once was, and US manufacturing is no longer as expensive. As the labor equation has balanced out, companies—particularly the small to medium-size businesses that make up the innovative guts of America’s technology industry—are taking a long, hard look at the downsides of extending their supply chains to the other side of the planet.

“Companies are looking to base their decisions on more than just costs,” says Simon Ellis, head of supply-chain strategies practice at IDC Manufacturing Insights, a market research firm. “They’re looking to shorten lead times, to reduce the inventory they have to carry.” When accounting giant KPMG International recently asked 196 senior executives to list their top concerns for 2011 and 2012, labor costs ranked below product quality and fluctuations in shipping rates and currency values. And 19 percent of the companies that responded to an October survey by MFG.com, an online sourcing marketplace, said they had recently brought all or part of their manufacturing back to North America from overseas, up from 12 percent in the first quarter of 2010. This is one reason US factories managed to add 136,000 jobs last year—the first increase in manufacturing employment since 1997.

The US certainly isn’t on the verge of recapturing its past industrial glory, nor can every business benefit by fleeing China. But those that actually build tangible goods should no longer assume that “Made in the USA” is an unaffordable luxury. Unless a company is hell-bent on selling the cheapest goods possible, manufacturing at home makes more sense than it has in a generation.

China’s big manufacturing advantage has been cheap labor, but wages—while still low compared with those in the US—have risen sharply in recent years.

The heyday of offshoring

Think of offshoring as a technology. Like any relatively young and successful innovation, it enjoyed a honeymoon period during which everyone scrambled to adopt it, lest they miss out on the gold rush. But now many companies are starting to grapple with this new technology’s limitations.

The core component of offshoring, of course, is cheap labor. In 2000, when Congress was preparing to vote on normalizing trade relations with China, political opponents of the bill gave their colleagues satchels containing three pennies—supposedly the average hourly wage for Chinese workers. That figure was exaggerated, but the spirit of the stunt rang true: US manufacturers couldn’t possibly compete with China’s blend of rock-bottom wages and rising technical savvy. Once the bill passed, the offshoring trickle that started in the 1980s became an unbridled flood.

Chinese factories deftly took advantage of this situation by making it easy for even the smallest US startups to find manufacturing partners. Factories polished their English-language outreach and established ties with professional middlemen. Soon anyone with a blueprint and modest capital could hire a Chinese factory to stamp out 20,000 units of a video tripod, an ergonomic joystick, or an espresso machine.

But the system has started to overheat. Manufacturing wages more than doubled in China between 2002 and 2008, and the value of the nation’s currency has risen steadily. It’s now under tremendous international pressure to let the yuan appreciate even more, and the country must cope with worrisome inflation at home (food prices rose by nearly 12 percent last year). And though Chinese workers still earn a fraction of what their American counterparts do, the rising costs of labor there are prompting companies to reevaluate their production strategies.

Once they do, these businesses often realize something profound: China isn’t the great deal they expected. A January 2010 survey by the consulting firm Grant Thornton found that 44 percent of responders felt they got no benefit from going overseas, while another 7 percent believed that offshoring had actually caused them harm.

One big reason for this growing dissatisfaction is quality. Like Sleek Audio, countless US firms have received long-awaited shipments only to discover that the products are too flawed to sell. This problem is due largely to China’s success: Factories are so overbooked that they have no choice but to favor their biggest clients. The smaller customers can end up facing long delays or hastily assembled products (or both).

“If you’re a huge company like Apple, you can get the whole factory to work for you,” says Paul King, founder of Hercules Networks, a New York company that makes charging kiosks for mobile devices. “You can put your own process in place, you can have your own quality control. But without that kind of power, you’re just another customer, and they don’t really care.” King cycled through three Chinese factories from 2008 to 2010 before giving up on offshoring due to persistent manufacturing errors—LCDs that winked out after six months, lights that broke when tapped even gently. The quality woes have disappeared now that Hercules is making its kiosks in the US, King says, and the company is thriving.

To deal with their production backlogs, many Chinese factories have started subcontracting work to facilities located in the center and western areas of the country, where labor costs are cheaper than on the industrialized coasts. But this usually makes the problems even worse. “They’ll subcontract your work without providing the subcontractor with the same training that you provided to them,” says George T. Haley, a professor of industrial and international marketing at the University of New Haven who specializes in Chinese business. “Then all of a sudden, your quality assurance goes all to hell.”

In addition to quality issues, subcontracting also exacerbates a second major problem with Chinese manufacturing: the lack of safeguards on intellectual property. The more subcontractors that get their hands on a design, the greater the odds of IP theft. Peerless Industries, an Illinois company that makes flatscreen and projector mounts, learned that lesson the hard way. “Knockoffs of our products started showing up in markets here in our own backyard,” says Michael Campagna, Peerless Industries’ chief operating officer. “It wasn’t necessarily our supplier doing it—it was our supplier’s supplier.”

Finally, sheer distance remains an intractable problem. Shipping costs nose-dived in the wake of the 2008 financial crisis but have since crept up as oil prices drift back toward $90 a barrel. And then there’s simply the time it takes to get goods from China. With credit hard to come by these days, companies are reluctant to tie up cash in inventory that takes three to six months to manufacture, ship, and clear customs.

When you include all the various drawbacks and costs that don’t appear in a factory’s price quote, manufacturing certain high tech goods in China can end up being surprisingly expensive. In 2008, three McKinsey consultants analyzed the production of midrange servers, taking into account everything from shipping to quality to exchange rates. They concluded that fabricating such devices in China made sense in 2003, when the required labor was 60 percent cheaper there than in the US. At that time, they estimated, the per-unit savings ran about $64. But this advantage, McKinsey concluded, had vanished by 2008: “After factoring in the higher labor and freight costs, we find that the former offshore savings have turned negative—a burden of an extra $16.”