The peanut butter and jelly sandwich is a classic childhood dish, and many adults still enjoy it as a throwback meal. It’s so ubiquitous that, in the U.S., the average schoolchild eats about 1500 PB&Js before the end of high school. The growing number of people with peanut allergies may threaten this lunchbox staple’s popularity, but for now it remains an American favorite. In honor of National Peanut Butter and Jelly Day (April 2), we’re taking a look back at the somewhat surprising history of the sandwich.

The Origins of Peanut Butter

Before we get into the PB&J itself, let’s delve into the delicious details of one of its key ingredients: Peanuts were first grown in South America, and were being ground; in the 16th century, Garcilaso de la Vega noted that “with honey [the peanut] makes an excellent marzipan.” Global trade then introduced peanuts to Europe, then to the Philippines, China, the East Indies, and beyond beginning in the mid-1500s.

In the 1700s, enslaved Africans brought peanuts back to the Americas and, a century later, they were an integral crop in the south. During the Civil War, Confederate troops were given peanut rations; it marked the first time the military created spikes in peanut consumption‚ though it wouldn't be the last.

In the late 1800s, there was a burst of peanut-related innovation. First, in 1884, a Canadian doctor named Marcellus Gilmore Edson patented a peanut paste. Then, in the mid-1890s, Dr. John Harvey Kellogg applied for a patent to create a nut paste. On the application he claimed that the resulting substance “has a decidedly meaty flavor and, with a little salt added, is a very agreeable article of food … It may be used as a substitute for meat or ordinary butter and utilized in various other ways as a new article of food.”

According to Peanuts: The Illustrious History of the Goober Pea, peanut butter was initially a highbrow spread; it appeared in sandwiches at high teas with watercress and pimento.

Peanut Butter Jelly Prime Time

So, how did peanut butter become an ingredient in one of the most famous, and humble, sandwiches in America? Julia Davis Chandler published the first peanut butter and jelly sandwich recipe in 1901 in the Boston Cooking School Magazine of Culinary Science and Domestic Economics. She wrote, “For variety, some day try making little sandwiches, or bread fingers, of three very thin layers of bread and two of filling, one of peanut paste, whatever brand you prefer, and currant or crab-apple jelly for the other. The combination is delicious, and, so far as I know, original.”

A 1920s boom in the commercial peanut industry made the spread more affordable and brought peanut butter from high society to the family table. Manufacturers also started adding a bit of sugar to the mix, which appealed to kids’ palates. The National Peanut Board says the sandwich became a family staple during the Great Depression, when it served as a belly-filling, high-protein, and inexpensive meal.

But it was World War II that truly made the PB&J a household name. From 1941 to 1945, both peanut butter and jelly appeared on the U.S. military’s ration menus, and some believe that soldiers began combining the two to make peanut butter more appetizing. When the soldiers returned home, they reached for the familiar comfort food again. Rationing also played a role in ensuring PB&J’s popularity stateside: While many staples, like butter and sugar, were rationed, peanut butter was not. That, combined with peanut butter’s inexpensiveness, helped the sandwich’s popularity as a family meal grow.

Today, there are many variations on the classic, including ones that incorporate different types of nut butters (such as almond) and varieties of jelly beyond the traditional grape (even including substitutions like honey, bananas, and marshmallow fluff to create the “fluffernutter”). But there’s something to be said for a classic PB&J. It’s an enduring—and delicious—piece of Americana.