Bedfordshire Police said officers were called to a report of a 47-year-old man with gunshot injuries in Portland Road at 9.50pm BST on Thursday 5 April.
The imam was taken to hospital with minor injuries.
The second man aged 30 was seriously injured after being shot in the face.
Police have arrested two men from Luton, aged 30 and 32.
Detective Inspector Craig Laws said the shooting was “concerning” but officers were treating it as an “isolated” incident.
The Luton Council of Mosques said: “Two people were injured including an Imam, neither [cases] are life threatening.”