The German composer Johann Sebastian Bach famously loved coffee so much that he wrote an entire ten-movement cantata about it. The so-called Coffee Cantata, or rather, as it is properly known, Schweigt stille, plaudert nicht (“Be still, stop chattering”); received its debut performance in a Leipzig coffeehouse in 1735. Throughout history, however, not everyone has shared Bach’s enthusiasm.

In 1511, for instance, the governor of Mecca outlawed coffee because he believed that its stimulating effect promoted radical thinking. Likewise, when Murad IV ascended to the throne as Sultan of the Ottoman Empire in 1623, he instantly outlawed coffee on pain of a beating for a first offense and being thrown into the Bosporus Straits for a second offense. And when coffee first arrived in Italy, many of the country’s most pious religious leaders labeled it a “satanic” influence and campaigned for it to be banned; it took Pope Clement VIII just one sip of the drink to turn down their request. He instead branded coffee so delicious a drink that it should be baptized!

Of all the historical figures who have tried to do away with everyone’s cup of Joe; however, perhaps the most unwise was the Prussian leader King Frederick II.

Frederick ascended to the Prussian throne as King Frederick II in 1740 and ruled over the kingdom for the next 46 years, longer than any other of Prussia’s legendary Hohenzollern dynasty of rulers. During his reign, Frederick greatly expanded Prussia’s territory, its military, and its power and influence across Europe, as well as establishing a great many cultural institutions, forging a reputation as a tireless patron of the arts, and ensuring Prussian artists made a lasting impact on the European Enlightenment. For all of that, he rightly became known to his people as Frederick the Great.

One less successful impact King Frederick had on his kingdom, however, came in 1777, towards the end of his reign.

Frederick reportedly became dismayed that many of his subjects were now coffee drinkers and Germany’s local beer producers were suffering as a result. Coffee houses were now taking business away from inns and drinking halls across the Prussian kingdom, and fearing the tax duties that he and his government would lose from a drop in alcohol sales, Frederick decided to take decisive action.

First, in 1777, he published an official royal manifesto on the entire subject, hoping to dissuade the Prussian people from drinking coffee. “It is disgusting to notice the increase in the quantity of coffee used by my subjects,” he wrote, “and the amount of money that goes out of the country in consequence. Everybody is using coffee. If possible, this must be prevented.” The King’s solution to the problem, however, was not quite what you might expect.

“My people must drink beer,” Frederick continued. “His Majesty was brought up on beer, and so were his ancestors and his officers. Many battles have been fought and won by soldiers nourished on beer, and the King does not believe that coffee-drinking soldiers can be depended upon to endure hardship or to beat his enemies in case of the occurrence of another war.”

Next, he decreed that all coffee producers in Prussia be officially licensed by the government, but then, to control consumption of the drink, he turned down most coffee houses’ license applications, permitting only those operated by friends and associates of his court. Finally, in 1781, he began employing teams of soldiers who had been injured (and therefore could no longer perform front-line military duty) to instead wander the streets of his kingdom, smelling the air for signs of illegally roasted coffee. Within a few years, Frederick was effectively running a monopoly on Prussia’s coffee trade and continued to do so for the remainder of his reign.

As for Frederick himself? He reportedly loved coffee. According to royal records, he began each day by waking before dawn and drinking half a dozen cups of coffee flavored with peppercorns and mustard.