MARIPOSA — Caltrans is closing a key route into Yosemite National Park ahead of expected heavy rains.

Starting at 2 a.m. Thursday, Highway 140 will be closed for about 17 miles from Bear Creek to Foresta Road, where the Ferguson Fire raged earlier this year. The state agency said the closure will end depending on the impact of ongoing inclement weather.

Caltrans is basing its decision on a forecast that calls for more than an inch of rain per hour, beginning at 4 a.m. and continuing through 8 p.m. The deluge could cause mudslides and debris flows in the burn scar.

“Please avoid road closures at all costs,” the state agency said in a news release Wednesday, “and remember, when driving in rainy weather — turn around, don’t drown.”

El Portal Road, a continuation of Highway 140 into Yosemite National Park, may remain open, providing access only between El Portal and Yosemite Valley, according to park officials. Call 209-372-0200 to check road conditions inside the park.

For updates on the Highway 140 closure, call 800-427-7623.

Caltrans on Wednesday also closed scenic Highway 1 at Mud Creek and Paul’s Slide as a precaution. A slide at the former location buried the roadway in millions of tons of earth in May 2017.