The story goes that Milton Friedman was once taken to see a massive government project somewhere in Asia. Thousands of workers using shovels were building a canal. Friedman was puzzled. Why weren't there any excavators or any mechanized earth-moving equipment? A government official explained that using shovels created more jobs. Friedman's response: "Then why not use spoons instead of shovels?"

That story came to mind last week when President Obama linked technology to job losses. "There are some structural issues with our economy where a lot of businesses have learned to become much more efficient with a lot fewer workers," he said. "You see it when you go to a bank and you use an ATM, you don't go to a bank teller, or you go to the airport and you're using a kiosk instead of checking in at the gate."

The president calls this a structural issue—we usually call it progress. And it isn't exactly a new phenomenon. It's been going on for centuries, and its pace has accelerated over the past 50 years. Businesses relentlessly look for ways to replace workers with machines. The machines get better and smarter. We go from spoons to shovels to excavators, not the other way around.

Telephone switchboard operators lose jobs to automated switching. Toll collectors get replaced by E-ZPass. Auto workers get replaced by robots.

The magnitudes are stunning. As the Washington Post reported in 2007:

"The textile industry has been particularly aggressive in replacing people with machines. A half-century ago, a typical North Carolina textile worker operated five machines at once, each capable of running a thread through a loom at 100 times a minute. Now machines run six times as fast, and one worker oversees 100 of them."

That's a 120-fold increase in output per worker. When a worker is 120 times more productive, you usually don't need as many workers as you did before.

Associated Press

Or look at eggs. Today, a couple of workers can manage an egg-laying operation of almost a million chickens laying 240,000,000 eggs a year. How can two people pick up those eggs or feed those chickens or keep them healthy with medication? They can't. The hen house does the work—it's really smart. The two workers keep an eye on a highly mechanized, computerized process that would have been unimaginable 50 years ago.

But should we call this progress? In a sense it sounds like a deal with the devil. Replace workers with machines in the name of lower costs. Profits rise. Repeat. It's a wonder unemployment is only 9.1%. Shouldn't the economy put people ahead of profits?

Well, it does. The savings from higher productivity don't just go to the owners of the textile factory or the mega hen house who now have lower costs of doing business. Lower costs don't always mean higher profits. Or not for long. Those lower costs lead to lower prices as businesses compete with each other to appeal to consumers.

The result is a higher standard of living for consumers. The average worker has to work fewer and fewer hours to earn enough money to buy a dozen eggs or a pair of shoes or a flat-screen TV or a new car that's safer and gets better mileage than the cars of yesteryear. That higher standard of living comes from technology. It isn't just the rich who get cheaper TVs and cars, plus the convenience of using an ATM at midnight.

Somehow, new jobs get created to replace the old ones. Despite losing millions of jobs to technology and to trade, even in a recession we have more total jobs than we did when the steel and auto and telephone and food industries had a lot more workers and a lot fewer machines.

Why do new jobs get created? When it gets cheaper to make food and clothing, there are more resources and people available to create new products that didn't exist before. Fifty years ago, the computer industry was tiny. It was able to expand because we no longer had to have so many workers connecting telephone calls. So many job descriptions exist today that didn't even exist 15 or 20 years ago. That's only possible when technology makes workers more productive.

It's true, there are some structural issues in the labor market. New jobs are being created but not at the usual pace and not fast enough to soak up the unemployed. But President Obama is wrong to blame innovation. A bigger problem is housing, where hundreds of thousands of workers have lost their jobs. The source of that problem isn't technology but an over-reaching housing policy and distorted finance. The solution is to let the housing market clear—let interest rates rise, stop subsidizing mortgages, and clean up the foreclosure mess. That would let housing starts return to something like normal.

The other challenge is simply confidence. Businesses aren't hiring because they're uneasy about the future. There's no easy way to instill confidence, but we know how to kill it—create uncertainty about taxes and regulations. Reducing that uncertainty would certainly help.

In the meanwhile, enjoy the ATM machine and the kiosk at the airport with a clear conscience. Doing more with less is the road to prosperity. When confidence returns, even more Americans will share in the bounty from innovation.

Mr. Roberts is a professor of economics at George Mason University and a research fellow at Stanford's Hoover Institution.