A US defence lawyer’s trousers caught fire as he presented his closing arguments in an arson trial on Wednesday.

Stephen Gutierrez was arguing that his client’s car spontaneously combusted when — right on cue — smoke began billowing out of his right pocket, witnesses told the Miami Herald.

Mr Gutierrez, who had reportedly been fumbling in his pocket as he addressed the jury, rushed out of the courtroom as his trousers burst into flames.

The jurors were also evacuated for their own safety, the Herald reported.

Mr Gutierrez quickly returned with a singed pocket, claiming the battery in his e-cigarette had malfunctioned.

He insisted the incident was not an elaborate stunt, staged to bolster his client's defence.

“It was surreal,” a witness told journalists.

“A lot of people could have been hurt,” another added.

Police are reported to be investigating the incident. Mr Gutierrez could be charged with contempt of court if investigators conclude he ignited his trousers on purpose.

Mr Gutierrez was defending Claudy Charles, 48, who was accused of deliberately setting his car on fire in South Miami-Dade.

Shocking moment an e-cigarette explodes in man's pocket

Charles was later convicted of second-degree arson.

E-cigarettes are powered by lithium-ion batteries – a particularly volatile type of rechargable cell that has been linked to spontaneous fires in smartphones and other electronic devices.