The permissibility of music has been contested in Iran since the onset of Islam in the seventh century AD when Muhammad passed and his companions sought to keep men's minds away from malahi (forbidden pleasures): wine, women and song. While the Koran doesn't condemn music per se, it claims that music can lead to a loss of reason resulting in "uncontrollable behaviour" and an "inflammation of passions".
After the Prophet's death, Islamic purists began to collect his sayings, or hadith. One ancient hadith says: "Listening to music leads to discord, just as water leads to the growth of vegetation." Hadith were then used by legists to effectively forbid music, save that tolerated by Muhammad. Music in Iran was to uphold these Islamic standards and abide by the Islamic moral code established by the Koran and the hadith.
However (in)compatible it may be with Islam, music is deeply rooted in the country's rich and diverse history. In addition to the practice of halal (compatible) music, Iranians have historically maintained the practices of makruh (blameworthy yet tolerated) and haram (incompatible) music.
Before the advent of music reproduction and other information communication technologies (ICT), music – underground or not, halal or haram – was confined to physical locations in real-time, historically controllable by authorities with centralised power in a physically and temporally confined country.