How the oracle worked was not a secret. She sat in a small underground room, breathing vapors from the ground and drinking water or inhaling mist from the warm spring beneath the temple. She entered an exalted state of mind and gave advice as if in a trance. Sometimes she didn't make much sense; sometimes her answers went over her questioner's head. On at least one occasion, she went into seizures and died.
Plutarch, who ran the temple for many years, wrote that the gases of the oracular chamber smelled sweet, like flowers. He also studied the history of the temple and made some shrewd observations. By his time, late in the first century CE, the oracle was not considered as powerful as in old times and the gases were not often present in the chamber. He surmised that the vapors came from a source deep in the Earth that was slowly losing its potency, and he thought that the great earthquake of 373 BCE had closed off some of the passages leading up to the surface.
Modern scientists have tended to doubt Plutarch's explanation, but it looks like their reasoning was wrong. The first serious excavations at Delphi, in the early 1900s, found no fissures and detected no gases, but that proved nothing. Fissures can be very small, and they can be sealed over the centuries by mineral deposits. And it was already known that the gases had disappeared. The mistake was in thinking about where the gases had came from—until recently, only hot vapors from volcanic sources were considered.
An article in the August 2001 Geology (here's the abstract) describes some geologic factors that make the Delphic temple a likely site for underground gases. Not only is there a major fault passing east-west directly under the temple, but another newly described fault cuts the site going north-south. Therefore the rock beneath the temple is full of cracks, able to pass groundwater and gases. The temple building sits upon several present and former springs.
Also, the Delphi region is underlain by a large body of limestone. Limestone tends to become highly porous as groundwater dissolves its minerals—this is why caves are found almost exclusively in that rock type. And this is not just any limestone, but one containing bitumen, organic remains that give rise to underground oil and natural gas.
The research team, led by Jelle Z. de Boer of Wesleyan University, examined pieces of travertine—a limestone stalactite deposited by an ancient spring—to see what gases they might have trapped. They also looked for hydrocarbon gases in the modern spring water. The light gases methane and ethane were detected in measurable amounts.
But the telltale gas de Boer's team found was ethylene. They also found ethylene at other Greek "gas springs" and natural tar pits. Ethylene is an important industrial gas today, so we know a lot about it. First, it's an effective anesthetic that produces euphoria and excites the nervous system. Second, it has a sweet smell.
As a result, we have a persuasive explanation for how the Delphic Oracle worked physically. De Boer concludes, "Our research has confirmed the validity of the ancient sources in virtually every detail, suggesting their testimony on geology is of more value than has recently been held to be the case."
One matter that's still uncertain, in my judgment, is the source of heat to vaporize these gases and warm the springs. De Boer suggests, without citing a source, that the activity along faults can produce enough heat to account for the effects. It's true that fault movements create heat (enough to actually melt rock in some cases), but I think that we also have to consider the energy released by underground microorganisms as they eat petroleum. This is a new area of research, and I don't have sources to cite either, but we are finding life deeper and deeper in the Earth, and I expect to be amazed at what we learn in the next few years. There's plenty of mystery left in this planet.
I think, too, that having a scientific explanation doesn't lessen my wonder at what the Delphic Oracle meant to the ancients. It puts me in awe of how strong the institution was and how well it worked. And I marvel too at the power science has to bring those long-dead people, whose culture roots our Western civilization, less distant from us.