“That smells terrible,” said seventh-grader Miles Higgins as he poured bleach into a beaker filled with purple cabbage juice. The solution immediately changed color to pale yellow; holding his nose, Higgins leaned closer to observe the transformation.

Science, it seems, is occasionally stinky.

Powerful odors, the whir of a blender, and children’s laughter emanated from a room at the Harvard Ed Portal in Allston recently as Higgins and six peers worked through a “Science and Cooking for Kids” lab. The hands-on program, now in its fifth year, is coordinated by the Harvard John A. Paulson School of Engineering and Applied Sciences (SEAS) and Harvard’s Public School Partnerships team to pique kids’ interests in STEM (science, technology, engineering, and math) through an approachable medium: food. The students took part in the week long class as part of the Ed Portal’s Summer Explorations program.

Miles Higgins adds lemon juice to a red cabbage juice solution in a lesson about the pH scale. Photo by Phoebe Grinnell/SEAS Communications

For this lesson on acids and bases, students poured different solutions into beakers of purple cabbage juice, which is pH-neutral. The solutions changed to different colors with the addition of each substance — the pale yellow liquid spiked with bleach, a strong base, stood in sharp contrast to the red solution that had received a few capfuls of acidic white vinegar.

Students then compared the results to color charts they made using pH paper.

“I was surprised by how mixing the liquids together led to such different results,” said Higgins, 12, of Boston. “I had always thought that science and food were in different categories, but there is a lot of overlap.”

Later in the lab, the young chefs-turned-scientists chopped fruits and vegetables to make salsa, and then tested the pH of their creations to better understand how acids and bases influence food flavors.

Sabah Vitale, an 11-year-old sixth-grader, had never made salsa, and enjoyed choosing and mixing ingredients that appealed to her. She has fun baking cookies with her family, but said the next time she bites into one she’ll think a bit harder about the science involved in the cooking process.

Sabah Vitale, of Brighton, an 11-year-old sixth-grader at Newton Montessori School, finely chops a tomato for salsa. Photo by Phoebe Grinnell/SEAS Communications.

“Sometimes, chemistry will surprise you,” said Vitale, of Brighton, as she finely chopped a tomato. “With science, there is always something new to learn.”

Sparking an interest in science is the goal of the free summer program, which included a week of lessons focusing on topics like the chemistry behind emulsions (kids made salad dressing from scratch), and the role of legumes in nitrogen fixation (they whipped up batches of hummus.)

For program leader Frank Mooney, a math teacher at Leominster High School, it is always rewarding to see the wonder on their faces when kids watch (and taste) the culinary results of a scientific experiment. Mooney, who helped originate the program and runs it with Kathryn Hollar, director of educational programs at SEAS, said emphasizing the connection between cooking and science is a great way to show that the applications of STEM are far from boring.

“Everyone has some sort of food that excites them, and often that’s what it takes—to find one point of interest they can use as a springboard to jump off and explore science from there,” said Mooney.