A 23-year-old man has been arrested and charged after he allegedly rammed his car into the gates of a Queensland mosque while hurling insults at worshipers inside.

Police say the incident took place outside Baitul Masroor Mosque in Stockleigh on Saturday night, hours after the suspect had been taken into custody for driving under the influence.

The driver is alleged to have slammed his car into the gates around 7pm, causing minor damage to the property, and 'shouted offensive words' through the window, before driving back home where he was arrested.

He was further charged with one count of wilful damage, commit public nuisance and driving a motor vehicle whilst suspended.

Police say the incident took place outside Baitul Masroor Mosque in Stockleigh (pictured) on Saturday night, hours after the suspect had been taken into custody for driving under the influence

About five hours earlier at 2.20pm, the Browns Plains man had been stopped on Buckley Road where authorities administered a roadside drug test which tested positive.

He was issued with a 24hr driver's license suspension and a notice to appear in court for one count of driving a vehicle whilst relevant drug is present.

Hours later, the man took to the road again, this time driving along Neville Street and pulled into the place of worship.

The incident occurred just a day after a gunman shot up a New Zealand mosque in Christchurch killing at least 50 people.

A spokesman for the mosque, however, said the incident was 'random' and not connected to the massacre, the Courier-Mail reported.

Baitul Masroor Mosque had previously dealt with another 'disturbing' incident in 2017 when a severed pig's head was left outside the property.