In 1502, the monarchy forced Muslims in Granada to convert to Catholicism or leave.
For hundreds of years, the Moors held Granada. Then in 1492 the Spanish Monarchy defeated them and took over. They considered the prominent religion Islam as wrong, so they declared that the people of Granada needed to convert to Catholicism. During this time they persecuted any Jewish or Muslim who did or did not convert.
Finally, in 1502, the queen decided she had finished waiting. She declared that all non-Catholics needed to find a new country or convert. Even though some left and others converted, still persecution reigned for the new converts. People accused them of secretly practicing their religion. This may have been true as Muslims went underground in this period in Spain. Now though Spain welcomes all religions.