Little wonder that Coca-Cola’s secret formula continues to have a hold on our imagination. Any popular product with a secret recipe excites curiosity, of course — think the colonel and Kentucky Fried Chicken — but Coke had some extra help.

Back in 1886, “Doc” Pemberton, a Civil War veteran with an aptitude for stirring up patent medicines, invented the first “cola” — a caffeinated soft drink meant to exploit the market for what was then considered a miracle drug, cocaine. Asa Candler quickly acquired it and made dramatic changes in it, notably a sharp reduction in the amount of caffeine and the elimination (almost) of cocaine. During the Candler era, the challenge of protecting the secrecy of Coca-Cola’s formula led to an amateurish but effective security procedure. Asa Candler’s son, Howard, and other trusted workers would scratch the name off all the packages, bottles and tins that contained the syrup’s ingredients, and then label them as numbered “merchandises,” including “7X,” the unique blend of flavors including oil of cassia or Chinese cinnamon.

There was no cult surrounding the formula, because soft drinks tended to be a back alley business selling “bellywash” that was not always of a consistent quality, or even sanitary. With the advent of the bottle cap in the early 1900s, the quality of the beverage quickly improved, and Coca-Cola became a popular product — so much so that in 1919, a group of Atlanta investors led by Ernest Woodruff, head of Trust Company of Georgia, organized a syndicate and bought out the Candler family, acquiring the Coca-Cola Co. for $25 million in what is widely considered the first leveraged buyout in American business history.

Coca-Cola’s name and logo are protected by trademark laws, but the formula itself cannot be patented, since doing so would require disclosing it. What Ernest Woodruff and his partners were buying was “goodwill,” as the intangible value of a popular product is formally known. To protect his investment, Woodruff hired a chemist, W.P. Heath, who learned the formula from the Candlers and wrote it down. For the first time in more than two decades, and after several significant changes, the secret formula was in written form.

At the end of World War I, the soft drink industry was nearly undone by a worldwide sugar shortage. Many beverages, including Pepsi-Cola, went bankrupt. The Coca-Cola Co. borrowed millions of dollars from New York banks to buy sugar, using the only collateral of value at hand — the written formula, neatly folded into a blue envelope. The formula remained in New York until 1925, when the loans were finally paid off. By then, Ernest Woodruff’s son, Robert, had become president of the Coca-Cola Co. Robert Woodruff traveled to New York City by train, retook custody of the formula, accompanied it home to Atlanta, had the blue envelope sealed with wax, and placed it into a vault in the basement of Trust Company of Georgia, today’s SunTrust Bank, where it remains.

During the 1920s, it was Robert Woodruff, a secretive and enigmatic man, who deliberately invested the formula with the mystique still familiar today. Woodruff decreed that only two senior chemists within the company could know the formula at any given time. During the age of air travel, he forbade them from flying on the same flight. Eventually, one of the chemists who knew the formula, Roberto Goizueta, rose to become CEO of the company, and his familiarity with the recipe led him to take the unsentimental position that it required reworking — thus the disaster of New Coke in 1985.

I have no quibble with the cult of fascination about Coca-Cola’s recipe. That’s why I titled my book “Secret Formula.” But the notion that the formula appeared in The Atlanta Constitution back in 1979 and went unnoticed by its readership, a readership whose town was shaped by the largess of Coca-Cola and the many millionaires it spawned, is simply absurd. A cola recipe from an 1880s’ codex is a far cry from the 1919 formula in the blue envelope in the bank vault. Get hold of that blue envelope — and then we’ll have a secret we can talk about.

Frederick Allen, a former columnist for The Atlanta Constitution and commentator with CNN, is the author of “Secret Formula.”