Crews from Huddersfield Fire Station used cutting gear to remove the roof and free a driver after his car overturned in Almondbury last night.
The incident happened at around 11pm on Somerset road near its junction with Benomley Road.
A man in his late 40s was driving a Renault Clio along Somerset Road when the car overturned. It is thought that he collided with a parked car, no other vehicles were involved.
It took fire officers 20 minutes to cut away the metal posts and peel back the roof of the car to remove the man, who was conscious throughout the ordeal.
He was taken by ambulance to Leeds General Infirmary.
The extent of his injuries are not known.