Chocolate chip cookies are beloved. Reports vary as to how popular they are, but it is safe to say that billions of these concoctions are consumed each year. A basic recipe appears on every package of Nestle’s Toll House chocolate chips, and it is incredibly simple — get the listed ingredients together, mix, dole out by the tablespoon, and bake for about 10 minutes at 375 degrees Fahrenheit.

But while seemingly straightforward, the recipe turns out to be anything but — historically speaking, that is. After all, why would someone ever think to put chunks of semi-sweet chocolate into cookie dough? In retrospect, it makes sense — delicious sense — but who knew? As it turns out, before 1930, no one. The creation of these gooey masterpieces was an accident — the true story of which is still in debate.

Ruth Graves Wakefield was the owner of the Toll House Inn, then a well-known restaurant in Massachusetts. One day that year, she was making chocolate cookies, using a recipe which called for what we now know as chocolate chip cookies but with baking chocolate instead of chocolate chips. Unfortunately (or, perhaps, fortunately for us), Wakefield was all out of baking chocolate. So, according to Nestle (who ended up buying her recipe) she came up with an interesting idea: use chocolate chips instead. But, as luck would have it, the chips retained their shape, and the rest is history.

Maybe.

George Boucher, a chef who once worked at the restaurant, claimed that Wakefield was too talented and too knowledgeable a chef herself to make what Boucher postured as a novice mistake. He offered an alternative theory (which, conveniently, gives him a center role). In his version of the story, Wakefield was making regular sugar cookies — no chocolate involved, chips or otherwise — but left the electric mixer uncapped. The vibrating mixer shook the cabinet above, causing a few bars of chocolate to fall in. Before Wakefield could stop, the mixer broke the bars into chips, which, in Wakefield’s eyes (per Boucher) ruined the batter. Boucher claims that he convinced Wakefield to cook the dough anyway, and the pair created the tasty treats we now eat billions of each year.

In any event, two things are not in dispute: one, that Wakefield had a hand in the cookies’ creation, and two, that she sold the recipe to Nestle — in exchange for a lifetime supply of chocolate chips.

Bonus fact : Oreos aren’t chocolate chip cookies, but they are popular in their own right. Like anything else popular, there are plenty of Oreo copycats out there. Many may recall what is commonly believed to be one of them, a creme-filled chocolate sandwich cookie called Hydrox. But that belief is misplaced. Oreos debuted in 1912. Hydrox? 1908.

From the Archives: Zapped Chocolate: A neat discovery, made when the chocolate did melt.

Related: A 12 month subscription to a cookie of the month club. A pound of cookies delivered a dozen times a year. Expensive, but that’s a lot of cookies.