A man who was shot outside a mosque in south-west Sydney was the victim of an attack by local Islamic State (IS) supporters, a witness has said.

Rasoul Al Mousawi, 47, was shot in the head in an industrial area on Rosedale Avenue, near the intersection of Brunker Road at 1:15am (AEDT).

He has undergone surgery for injuries that are not life threatening.

A friend of the victim, a Shia Muslim who did not want to be identified, said a group of men drove past the Houssaineyat-Alnabialakram Association in Greenacre several times before the shooting, calling out "IS lives forever".

"They called us 'Shia dogs' and they threatened to come back down tonight and kill you, shoot you, whatever," the man said.

"We didn't believe them and we went home and we got a phone call that one of our community members got shot in the head.

"He was walking his family home so he can come back and do the cleaning (at the mosque) and they shot him in front of his family.

Rasoul Al Mousawi, 47, was shot in the head outside a Greenacre mosque. ( Supplied )

"His wife, she just fainted."

His daughter saw it all happen.

"My dad just held his neck and ran inside," she said.

"I was like, 'what's happening' and all I saw was blood running down his head and neck".

Police have not identified a motive for the shooting but said they were following several lines of inquiry.

They have ruled out the suggestion that the violence in Iraq may be spilling over into suburban Australia.

Police have told the ABC there is nothing to suggest the shooting is linked to IS.

IS is attempting to establish a caliphate in Iraq and Syria and they see Shia Muslims as opponents as they dominate the Iraqi government.

Victim had attended a prayer meeting

When officers arrived at the mosque, they found Mr Mousawi with pellet wounds to his face and shoulder.

"Police have cordoned off the area as a crime scene and are currently processing that scene," Inspector David Firth said.

"Police are speaking to a number of witnesses at the scene and are appealing for anyone with information who can assist with their inquiries to come forward, particularly those who may have seen a vehicle acting suspiciously in the area at the time.

NSW detectives depart after speaking to members of the Shia Muslim prayer hall. ( AAP: Paul Miller )

"We do have some CCTV footage of the street that may help us with our inquiries."

Inspector David Firth said the injured man was helped by other people before paramedics treated him.

"Witnesses assisted the man. Emergency services were called a short time later and the 47-year-old man was treated by paramedics before being taken to hospital," Inspector Firth said.

The witness said he and other Shia community members were at the Islamic Centre for a prayer gathering before the shooting took place.

"They shot an innocent guy, a family man. This is Australia, it's a safe country. How can this happen?

"That's not a human act, it's just not human what they did.

"And we just want them (the attackers) to know, we're not afraid of them."

Police have urged anyone with information to call Crime Stoppers.