Each year, Americans spend 37 billion hours waiting in line. By the time you head off to the great queue in the sky, you’ll have spent an estimated two to three years of your waking life staring at the back of the person in front of you, waiting to go through an airport metal detector, use the bathroom, or get past the velvet rope and into the club.

Nobody likes waiting in line, and nobody likes it less than economists. Lines, you see, are anti-market, an affront to the logic of supply and demand. A line is a response to an underpriced (or un-priced) good. It represents a value system where time, not money, is the effective currency. In economic terms, those 37 billion hours are a kind of general loss. Huddling in the pre-dawn chill for a cronut qualifies as neither production nor consumption nor leisure — it’s just pure economic inefficiency.

Advertisement:

Even still, lines have their defenders, like Harvard’s Michael J. Sandel, author of "The Moral Limits of Markets," who argues that they tend to do a good job allotting scarce goods to the people who value them most, the diehards. "Shakespeare in the Park" is a good example: Tickets to the Public Theater’s star-studded productions are free, but non-transferrable. You need to sit in the park all day to go to the show.

Opponents of this theory, like the economist Ed Dolan, counter that lines aren’t just a waste of time – they’re corrupt, less fair than the eminently transparent market. They engender cutting and nepotism and downright bribery.

Both points have some truth to them. But the line’s advantage is more basic. Beyond early risers and people with good shoes, the line has a natural constituency: those whose time isn’t worth much. If you’re a well-paid lawyer, working long days for a high hourly fee, two hours in line has a huge opportunity cost. For two hours of work, you could pay market price and have cash left over for dinner. If you’re unemployed, on the other hand, sitting in Central Park all day to see "Twelfth Night" for free might well be worth your while.

Advertisement:

In that sense, the line is a very egalitarian concept, demanding the only thing we’re all given in equal measure: time.

It may also be growing obsolete. Paying to skip has become common, from Six Flags’ Flash Pass to the TSA’s PreCheck system. Real-time markets, where price can be instantaneously aligned with demand, have been implemented to dispel throngs of diners and highway traffic. Where lines endure, they’re infiltrated by professional “waiters,” standing in for clients whose time is worth more.

Lines, in all their forms, are being subverted by markets.

Advertisement:

The most well-known example of a real-time market system is Uber’s surge-pricing algorithm. When cab demand is high (like on New Year’s Eve, or during a terrorist attack), the price of a ride goes up. This brings more cars into the streets and shortens the wait time for those who can afford them. It’s a pretty neat demonstration of supply and demand at work, an economist’s fantasy realized by the mobile Internet.

It’s easy to see who wins from surge pricing: drivers, Uber and customers willing to pay to get someplace quickly. Riders willing to share might also stand to benefit.

Advertisement:

It’s harder to see who loses, because the old way of getting a cab (sans smartphone) was so irritating. In the biggest cities, where cabs are hailed on the street, demand pricing displaces a complex hierarchy of street knowledge, aggressive behavior and luck. But in most places — airports, train stations, cities with phone-order cab distribution — fixed pricing and a supply shortage rewarded travelers who had waited the longest.

Lines still dominate the urban experience. Roller coasters, movie theaters, airports, restaurants, clubs, government offices, sample sales, traffic: all these places operate on some kind of first-come, first-served basis.

But that system is changing. Consumers are doing their part: The Web has made it easy to hire people to wait on your behalf. Shoppers can use companies like TaskRabbit to hire “waiters” for Black Friday sales or iPhone launches. In New York, Robert Samuel became a media darling for starting what may be the world’s first “wait-in-line” company, Same Ole Line Dudes (or SOLD). He puts his name down for pancakes at Clinton Street Baking Company while his clients sleep in; in the past month, he has also waited for cronuts, passports and early tickets to the new "Annie" movie.

Advertisement:

On the other side of the line, organizers and planners have long recognized the efficiency (and financial incentive) of pricing identical goods or services based on demand. Sometimes, these fees are static — like peak transit fare, or different menus for lunch and dinner.

More often, nowadays, they are dynamic, instantly sensitive to interest. That’s how highway travel works on the Katy Freeway, west of Houston, or on the express lanes along the Beltway and I-95 south of Washington, D.C. You’re guaranteed a faster trip — for a price. This is also how parking prices work in downtown San Francisco, and cities like Seattle and Cincinnati aim to follow suit.

There’s even surge pricing for beer, at the Exchange Bar and Grill in Manhattan and the Brew Exchange in Austin.

Advertisement:

In a way, the mystery is that simple lines persist so widely when the technology to eliminate them has arrived.

The restaurant industry is a good example. You can make arguments about fairness for public institutions like the DMV or the highway system. But why shouldn’t restaurateurs institute a form of surge pricing, charging a premium for weekend evenings and offering flexible customers a discount during weekday afternoons?

Nick Kokonas, the owner of three chic Chicago restaurants, is trying to change restaurant culture. His dynamic pricing app Tock, backed by a team of well-known chefs and investors, will launch at the end of this winter. For $695 a month, restaurants can use Tock to sell tickets for meals. Some tickets cover the whole dining experience (which works in a prix-fixe setting); others simply function as a deposit toward the bill.

Because ticket pricing is dynamic, getting a table could become something like getting an airplane ticket: Expensive on the weekends and with short notice, cheap in advance and at odd hours. The French Laundry, one of the most famous restaurants in America, will begin using Tock this year. (Chef Thomas Keller is an investor.)

Advertisement:

Economists, of course, like this system very much. Tyler Cowan, author of "An Economist Gets Lunch," thinks bidding on tables isn’t just more efficient, but fairer (presumably on the assumption that the allocation of money, ultimately, is fair).

Stretched to pay the reservation fee? Cowan suggests you skip dessert.

The progress of open markets for taxis and tables, though, shouldn’t be seen as a kind of concession to the plutocracy. The very rich have always had full-time employees to do the dull work of waiting. They don’t need Uber; they have drivers. They can hire Thomas Keller to commandeer their home kitchen for a night.

The real winners are in the strata below, those who could never have afforded the premium options, the chartered flights and private dinners. They could never buy out of the line entirely – but now they can buy their way to the front.