Water is urban planners’ nemesis. Because the built environment is so impervious to liquid, thanks to all that asphalt, concrete, and brick, water accumulates instead of seeping into the ground. That’s how you get the extreme flooding that has plagued California for weeks, so far killing 19 people and causing perhaps $30 billion in damages.

Traditionally, engineers have treated stormwater as a nuisance, building out complex infrastructure like drains and canals to funnel the deluge to rivers or oceans before it has a chance to puddle. But in California and elsewhere, climate change is forcing a shift in that strategy. As the world warms, more water evaporates from land into the atmosphere, which itself can hold more water as it gets hotter. Storms in the Golden State will come less frequently, yet dump more water faster when they arrive. Stormwater drainage systems just can’t get the water away fast enough.

To prepare for this soggy future, engineers are turning to another plan for flood control, forcing water to seep underground into natural aquifers. Such a plan will simultaneously mitigate flooding and help the American West store more water despite a climate gone haywire. “We need to think a little bit more creatively about: How do we most effectively utilize basically these huge underground sponges that we can use to supply potable water?” says Katherine Kao Cushing, who studies sustainable water management at San José State University.

California’s water system is built for a squirrelly Mediterranean climate. Rains in the autumn and winter fill up a system of reservoirs, which feed water across the state throughout the bone-dry summer. But that system strains during a drought, like the one that’s been ravaging the state: The past three years have been the driest three-year period since 1896. (Drought can actually exacerbate flooding, since parched ground doesn’t absorb water as well.) Before this series of storms hit, some of California’s reservoirs had almost dried up. Now statewide reservoir storage is nearing the historical average. That’s how epic this rainfall has been.

Snowpack is also important. It grows at high altitudes through the winter, then melts and feeds reservoirs as temperatures rise. But climate models predict that a significant fraction of the state’s snowpack will be gone by 2100, says Andrew Fisher, who runs the University of California, Santa Cruz’s Recharge Initiative, which studies groundwater resources. “Some of the models say all of it,” Fisher adds. “Let that sink in for a second. That’s more water than behind all the dams in the state. It’s very sobering because there is no way we’re going to double the number of dams.”

To hydrate its people and agriculture, California is stepping up water conservation efforts, like getting more low-flow toilets into homes and paying people to rip out their lawns, which are terrible for all kinds of reasons beyond their thirstiness. It’s recycling wastewater from homes and businesses into ultra-pure water you can actually drink. But most of all, it’s trying to hold onto its sporadic rainwater, instead of draining it away, building out infrastructure to create “sponge cities.” These are popping up all over the world; the concept has been widely deployed in China, and city planners in places like Berlin in Germany and Auckland in New Zealand are using it to come to grips with heavier rainfall.