John Collins, 93, accidentally drove his car into a canal in Bakersfield. The swift water carried the vehicle a half-mile down the canal.
Police said the trunk then opened and caught one of the safety lines across the canal.
This enabled Collins to crawl out the sunroof before rescuers got ropes and a life jacket to him.
He was pulled to safety and taken to the hospital. His condition was not immediately known.