The incident happened around 2 a.m. in a parking lot in Medford.
The man apparently dropped his keys in the drain and then used his car to pry the 200-pound grate off.
He became trapped when the rope he used to get down to the bottom was too short, and he fell.
Firefighters used a ladder to reach the man, who was 30 feet below ground.
He wasn't hurt, and he was able to leave with his car keys.