The clash took place at Hindpiri colony on Wednesday, Sep 1, over loudspeakers being used on the occasion of Janmashtami, the birth of the Hindu god Krishna.
Some Muslims opposed the loudspeaker being used at Tarabi, the prayer offered during Ramadan in the evening.
Members of both the communities accused each other of creating trouble in the area and pelted stones on each other and fired gunshots.
Police reached the spot to control the situation. Two policemen were also injured in the stone-pelting.
Two people were injured in the firing and six in the stone-pelting, a police official said.
Inspector general of police (Ranchi zone) Rezi Dundung and senior superintendent of police Praveen Kumar took command and the situation was brought under control around 12:30am on Thursday, Sep 2.
The injured were admitted to the Rajendra Institute of Medical Science and Seva Sadan.