You’ve just had dinner at one of the best restaurants in the country, the kind of place where the chef talks about his passion for perfection, obsession with detail and demand for the best, freshest ingredients. You know that there is probably one cook in the kitchen for every couple in the dining room. So you might feel surprised — even cheated — to discover that the coffee you are now enjoying was made by the waiter popping a capsule into a machine and pressing a button.

This is not a fanciful scenario. In the UK, more than 15 Michelin-starred restaurants use Nespresso, the market-leading capsule system, to make their coffee — including Heston Blumenthal’s Fat Duck in Berkshire, and The Ledbury in London. In France, Nespresso supplies more than 100 Michelin restaurants, including the legendary L’Arpège in Paris. Even in Italy, where the first espresso machine was patented in 1884, more than 20 Michelin restaurants use the new capsule system, and many others around the world use it or its rivals developed by Illy, Kimbo, Lavazza and Segafredo. Push-button espresso began as a domestic product, a way to simulate espresso at home without the mess and fuss. But in recent years it has rapidly, if quietly, started to take over the restaurant world.

You might not care much about fine dining or coffee. But you probably do value the skills of the artisan and might well believe that food is one of the ever-dwindling number of domains where individual human flair and creativity cannot be bettered by the mass-produced and mechanised. If so, you should care about the challenge to your assumptions that the rise of capsule coffee represents.

That concern lead me to a private dining room at the two Michelin-starred Latymer restaurant, part of the Pennyhill Park country house hotel in Surrey. With me were a coffee shop owner, two coffee obsessives, and a coffee-drinking friend. We were going to blind-taste three coffees: Nespresso capsule coffee, which is served in the restaurant; the traditional espresso that the hotel provides for room service; and a third unmarked coffee I had brought with me to be made the same way, just to see if the whole thing was nonsense and coffee is coffee is coffee. It was the artisan versus the machine, and given how top chefs had already voted with their contracts, the odds were against the result I instinctively preferred.

Ever since Alan Turing first suggested that we might be able to build a computer with an intelligence that could not be distinguished from a human’s, people have been trying to carve out a domain of activity that must be forever distinctly human. Chess grandmasters were once held up as exemplars of exactly what computers could not do. But after IBM’s Deep Blue computer defeated the world chess champion Garry Kasparov in 1997, this was quietly forgotten, and we looked instead to creativity, believing it absurd to think that a computer program could surpass Hamlet or Beethoven’s late string quartets.

With the benefit of hindsight, it now seems obvious that chess is just the kind of thing that computers could do well. The advent of capsule systems heralds pretty much the same realisation for espresso coffee. Coffee-making lends itself to automation, since all the key variables are strictly controllable. Technically, it’s relatively easy to get hold of the best coffee beans, roast them at the right temperature for the right time, grind them to the right fineness, and then vacuum-seal the right quantity for one shot. From that point on, the coffee will not degrade, effectively being as fresh once the machine pierces the capsule as it was when it went in. Then it’s a matter of hiring leading coffee experts, throwing millions of pounds of R&D at a crack team of engineers, and building a machine that will force the right amount of water through the coffee at the right temperature and pressure.

In theory, that is bound to result in a better brew than the traditional process, which, for all its romance, is full of opportunities for degradation and mishap. A bag of beans, once opened, will start to lose its flavour very rapidly once it is ground. Calibrating temperature and pressure is also difficult and subject to human error. While the capsule always contains exactly the same amount of coffee, the amount the traditional barista places in the portafiltro, and the degree to which is it compacted with the tamper, will always differ slightly. Most cafés do not get every step right, and they only get away with it because most people drown their espressos in steamed milk.

‘You have to function like perfect machines,’ Adrià was shown telling the kitchen staff at El Bulli

That’s all very well, but surely coffee is the exception, not the rule, to the artisanal qualities of food and drink? That could be a complacent thought, and ironically, the people whose work most suggests it is are currently at the vanguard of artisan cooking: the molecular gastronomers. Donning both lab coat and chef’s hat, these pioneers are exploring how the science of cooking and sensory perception can tell us the best ways to cook and prepare foods. At the moment, this approach requires enormous amounts of time and kit, and you can enjoy the results only at restaurants such as the Fat Duck, where they come at vast expense (£195 per head without service or wine).

But the logical consequence of molecular gastronomy is haute-mechanisation. If the best way to cook meat, for example, really is to vacuum-seal it with some herbs and spices and cook in water at 55 °C (131 °F) for 48 hours, then as soon as a suitable, cheap sous-vide cooker is available, there is no reason why a novice chef in a local pub, or anyone else for that matter, couldn’t collect it from the butcher and do as good a job as anyone else.

Even at El Bulli in Spain, voted the world’s best restaurant for a record five years before it closed in July 2011, this basic principle was evident. Head chef Ferran Adrià and his core team were not actually the ones preparing the food on the night. Their main role was to develop dishes, in a form of gastronomic R&D, during the six months of each year that El Bulli was closed. The restaurant kitchen itself was really just a very fancy production line. ‘You have to function like perfect machines,’ Adrià was shown telling the kitchen staff in the documentary El Bulli: Cooking in Progress (2011). If that’s true, then in the long run, why not simply use perfect machines in restaurant kitchens, just as computerisation and mechanisation took human beings off the production floors of car plants?

Mechanised production can be wonderfully democratising, turning all sorts of things that were luxury, bespoke items into things everyone could afford, like the car, central heating, and computers. In the gastronomic utopia of the future, no one need be condemned to thin, dishwater coffee, or pies with pastry like wet cardboard.

For most epicures, it is almost an article of faith that this will never happen, because food needs to be cooked with love, flair and passion. While this might conceivably be true at the very peak of culinary art, in most cases mechanisation is competing not against the artisanal best but against the human mean. So, even if the very best coffee is still made the traditional way by a skilled, human barista, all Nespresso need do is produce better coffee than the majority of baristas, whom most coffee fanatics describe as incompetent anyway.

The claim that handcrafted is better does not stand up a priori. It needs to be put the test. And for coffee, that’s exactly what I did.

The tasting was designed to be as blind as possible, with each taster trying each coffee in a different order, so as to counter any advantage or disadvantage that coming first or last might give. The coffees were brought in by a waiter, not by the experienced barista Bruno Asselin, who is also the manager of the Latymer restaurant at the hotel. He had thoroughly cleaned the traditional espresso machine, opened a fresh bag of beans, and ground them just before the tasting.

We tasted the three coffees in silence, scoring them on a scale from zero to seven points, and jotting down personal tasting notes. My scores were not used in the final reckoning because, in making sure that Bruno had understood the system, I had seen which coffee corresponded to each number. Then we totted up the scores.

In distant last place came the ground coffee I had brought, a very good quality, single-estate bean, but not roasted for espresso and ground four days earlier, a little too coarsely for Bruno’s machine. The traditional house espresso scored 18 points, and was the favourite of one taster. But the clear winner with 22 points was the Nespresso, which both scored most consistently and was the favourite of two of the four tasters. Of course, these were just four people’s opinions. But their consensus fits the judgment of top chefs and Nespresso’s own extensive testing, which must have been conclusive enough for them to have the confidence to agree to my challenge in the first place.

Does this herald the death of artisan coffee, except in those exclusive enclaves where the very best, most obsessive practitioners ply their trade? And is the writing on the wall for other areas of human excellence where we cling to the idea that artisanal is best? A lifeline might seem to be provided by the detailed reviews of the coffees we tasted. The key descriptors for Nespresso were ‘smooth’ and ‘easy to drink’. And from the point of view of restaurateurs who use it, the key word is ‘consistency’. It was far from bland, but it was not challenging or distinctive either. It’s a coffee everyone can really like but few will love: the highest common denominator, if you like. The second-place coffee had more bite, and was the favourite of myself and the 10-cup-a-day connoisseur, but scored a pathetic two points from one person on the panel who took against it.

That taster was actually a bit of a coffee nerd and he made the acute observation that what Nespresso had really done was to look at the coffee-making process and systematically remove all that is problematic in it. The result is something flawless, but that is a particular and limited form of excellence or perfection. Perhaps there are peaks above perfection that can be achieved only by accepting a certain amount of imperfection. A perfect bottle of cola will not be as good as an average meal at El Bulli, even if they screw up one of the 40 courses.

Yet even subtle variations might themselves be perfectible. One day it might be possible to produce mechanically the coffee that is just right for you, even perhaps for you just now rather than yesterday.

The only way truly to defend the artisans against all that technology might put up against them is to give up the entire premise of my blind tasting, that is, the idea that it does not matter how the coffee came to be, all that counts is its final taste.

Surely we appreciate the handmade in part because it is handmade. An object or a meal has different meaning and significance if we know it to be the product of a human being working skilfully with tools rather than a machine stamping out another clone. Even if in some ways a mass-produced object is superior in its physical properties, we have good reasons for preferring a less perfect, handcrafted one.

We are not simply hedonic machines who thrive if supplied with things that tick certain boxes for sensory pleasure and aesthetic merit

Corporations know this, which is why they will often use bogus personalisation to make their products seem more appealing, like putting a picture of a farmer on the label, or giving the product the name of a person or place. But do we have good reasons for this preference, or is it just romantic nonsense? I think we do. We live in a world of humans, other animals and things, and the quality of life depends on the qualities of the relationships between them. Mass production, like factory farming, weakens, if not destroys, these relationships. This creates a kind of alienation, where we feel no genuine, human contact with those who supply us with what we need.

We are not simply hedonic machines who thrive if supplied with things that tick certain boxes for sensory pleasure, aesthetic merit, and so on. We are knowing as well as sensing creatures, and knowing where things come from, and how their makers are treated, does and should affect how we feel about them. Chocolate made from cocoa beans grown by people in near slave conditions should taste more bitter than a fairly traded bar, even if it does not in a blind tasting. Blindness, far from making tests fair, actually robs us of knowledge of what is most important, while perpetuating the illusion that all that really matters is how it feels or seems at the moment of consumption.

This might seem a simple, even platitudinous point. But it has profound political implications. For if it is true, then the whole way in which efficiency is usually measured is fundamentally flawed. Take agriculture. Proponents of organics and other non-intensive, less petrochemically dependent forms of farming are often drawn into the game of defending their approach only by measurable, objective results. So the battle becomes a statistical debate over yield, water usage, carbon footprint, soil erosion, and so forth. The trouble is that the kind of human-scale farming that people like does not always win when judged by these metrics.

Of course, we need to think about yield, efficiency and environmental impact. But we also need to think about what kind of world we want to live in. And if we do, most of us would say that we would prefer food chains that preserve human links between consumer, farmer, land, and animals, in a landscape that combines functionality and beauty as much as is possible. We prefer to buy coffee traded between small groups of individuals rather than beans of the same quality, grown to the same environmental standards, but channelled through large multinationals with an exclusive right to supply the machine you buy from them. That is not to say we must shun technology, never use polytunnels, or insist that all chickens come from a nearby country lane. But it does mean it is legitimate to prefer forms of trade and artisan production that maintain links between individuals, communities, land, and animals.

It is not that handmade is always best, of course. Much technology is itself a testimony to human creativity and ingenuity. Apple has got very rich through supplying technology that is beautifully designed by humans who are as gifted as the best artisans. There is plenty that we should happily allow to be mechanised, for the obvious benefits that brings. But there is plenty else we will continue to prefer to be handmade, because what matters is not just the result, but the process by which you get there. Humans are imperfect, and so a world of perfection that denies the human element can never be truly perfect after all.