On a hot August day in 1816, waves of heat shimmered off of the dusty plazas and red tile roofs of the San Gabriel Mission community. The surrounding valley and foothills were brown and dry, and the nearby arroyos hadn’t run with water since March. But the town was a verdant oasis, watered by babbling brooks that ran alongside the vineyards, through the workshops, and into a 40-acre garden. These streams quenched the thirst of more than 1,700 Native American and Spanish inhabitants; of thousands of cattle, sheep, goats, pigs, horses, and mules; and of the fruits and grains that fed them.

But more than that, the water powered Southern California’s first center of industry, including a $20,000 a year cattle hide and soap export business. So impressive was the mission that one of the first visitors from the United States to this Spanish (and later Mexican) settlement remarked that its value was equal to a mine of silver or gold.

The extensive network of waterways was no product of nature—it was shaped entirely by human hands. And as it was improved, the system provided one of the most important early examples of industrial agriculture in western North America, and contributed directly to the rise of the young city of Los Angeles. It’s a story that reminds those of us gripped by one of California’s worst droughts on record that control over water has shaped our region’s destiny for centuries.

The San Gabriel Mission’s water system developed over a 60-year period through trial and error. The first version of the system, in fact, was an utter failure. Unaccustomed to Southern California’s fickle waterways, missionaries initially placed the mission in the fertile floodplain of the San Gabriel River in 1771. After four difficult years, the padres realized that the river’s annual flooding represented as much a threat as a blessing, and they relocated the small community to high ground. Rather than bringing the mission to water, they decided to bring water to the mission.

Tapping into artesian springs more than two miles to the north, the mission’s native Gabrieleño neophytes (captive laborers) hand-excavated a series of zanjas, or ditches, bringing precious water to the growing mission town. By the second decade of the 19th century, lit by the first rays of the dawning Industrial Revolution, clever, self-taught engineers had expanded the simple trenches into a vast system of rock-lined canals, brick and plaster reservoirs, dams, and water-powered grain and sawmills.

Only the broad outlines of the San Gabriel Mission water system’s scope and function have been preserved in the inventories, letters, and histories that the mission priests and their successors left behind. Few images, and no maps, survive from the mission’s active years, and those that we have fail to capture the details of the system. The story that was passed down has its flaws, however, being heavily biased in favor of the handful of men of European descent who designed and profited from these works. So how do we know what it looked like, and how it worked? The science of archaeology specializes in filling this kind of gap by exposing and interpreting the material remains of past human activity.

On another hot fall day in 2014, a team of archaeologists cleared nearly two centuries of soil away from the stone foundations of the San Gabriel Mission water system. Time had been surprisingly kind to the site. In a historical irony, the construction of a railroad atop the ruins in 1874, while initially destructive, had preserved the heart of the water works just across the street from the iconic mission church.

Another train project made the dig possible. The construction of the Alameda Corridor-East San Gabriel Trench, a project that will lower the Union Pacific Railroad tracks below the intersecting streets, required that the tracks be temporarily shifted to the north. This displacement represented a rare opportunity to examine the long-buried foundations, which underlay the entire railroad right-of-way, directly across the street from the mission church. My team of archaeologists excavated those foundations with machines and by hand to reveal the pattern, associated artifacts, and history of the waterworks’ construction.

Project planners have long known that archaeological materials were present in the area, prompting them to hire my firm of professional archaeologists in advance of construction. We have spent years documenting the physical remains of the mission, including numerous foundations and hundreds of thousands of artifacts and food remains. This latest dig has uncovered four major iterations of the water system: from simple earthen ditches, to cobblestone-lined canals and tanks, to masonry reservoirs connected by segmented ceramic pipes, to the pinnacle of the mission’s hydraulic technology—a massive cement flume that served as the millrace and millpond for a New England-style grain mill dating to 1825. In exposing and documenting these systems, we continue to be impressed by the innovation that marked their evolution, and the increasing sophistication that they gained as they were improved. This improvement was not simply about increases in scale—with each new version of the water system, the designers got better at conserving water. They did this not by reducing their use, but by recycling the water several times before releasing it downstream. The network of canals simultaneously powered mills, flushed tanning vats, watered animals, irrigated crops, and supported cooking, bathing, and washing needs.

We preserved the most intact portion of the 1825 flume two years ago by picking it up and moving it across the street to Plaza Park and installing a self-contained plumbing system. It once again flows with cool water so that visitors can experience the look, feel, and sound of the historic waterway. Our finds in 2014, however, included the largest and least expected element of the system, representing a kind of missing link between the earliest zanjas and the late Mission period millworks.

I have been conducting archaeological research for 20 years, excavating in Arizona, New Jersey, Honduras, British Columbia, Florida, and Peru. But much of my career has focused on the early history of Los Angeles. I have learned how deeply L.A.’s roots are entwined with water issues. After making the 9-mile walk from San Gabriel to their new town site, one of the first acts of Los Angeles’ pobladores (settlers) was to create their own Zanja Madre, a “mother ditch” connecting the Los Angeles River to their houses and fields. More than a century later, a former zanjero (ditch tender) named William Mulholland took the idea pioneered by San Gabriel’s missionaries to its logical end, bringing water from the Sierra Nevada to Los Angeles in a ditch of epic proportions, the Los Angeles Aqueduct.

As Los Angeles looks to the future, the thirst of its growing population remains to be satisfied. In both Los Angeles and her predecessor, San Gabriel, bringing water to the people was only half of the equation. The other half—seeking new ways to conserve the water—was the key innovation upon which this great city was first built, and will be built again.

John Dietler is the lead archeologist for the Alameda Corridor-East Construction Authority and the California cultural and paleontological resources program director at SWCA Environmental Consultants. He has a doctorate in anthropology, with a focus on archeology, from UCLA. He wrote this for Thinking L.A., a partnership of UCLA and Zócalo Public Square.

*Photo courtesy of Edward Headington.