Answer
In the Name of Allah, Most Gracious, Most Merciful.
All praise and thanks are due to Allah, and peace and blessings be upon His Messenger.
In this fatwa:
It is permissible to keep cats in the house, and there is nothing wrong with that because cats are not harmful or impure.
Answering your question, the Fatwa Center at Islam Q&A states:
Keeping cats in Islam
It is permissible to keep cats in the house, and there is nothing wrong with that because cats are not harmful or najis (impure).
With regard to cats not being harmful, no one disputes that, rather they are useful because they eat snakes, rats, bugs and other things that may be in the house or yard.
Are cats impure in Islam?
With regard to cats not being najis, this is known from the hadith of Kabshah bint Ka’b ibn Malik, who said that Abu Qutadah – her husband’s father – entered upon her and she poured water for him to do wudu, and a cat came to drink from it, so he tipped the vessel for it to drink. Kabshah said: “He saw me looking at him and said, “Do you find it strange, O daughter of my brother?’ I said, ‘Yes.’ He said, ‘The Messenger of Allah (peace be upon him) said, “They (cats) are not najis, rather they are of those who go around amongst you.”’” (At-Tirmidhi, An-Nasa’i, Abu Dawud, Ibn Majah, classed as sahih by al-Albani. Ibn Hajar narrated in at-Talkhis that Al-Bukhari classed it as sahih).
Animal welfare in Islamic tradition
Ibn `Umar (may Allah be pleased with him) said: The Messenger of Allah said: “A woman entered Hell because of a cat which she tied up and did not feed, nor did she let it loose to feed upon the vermin of the earth.” (Al-Bukhari and Muslim)
The vermin of the earth means insects and mice, etc.
This hadith does not denounce the woman for keeping a cat, but it demonstrates that the woman’s sin was in not feeding it or leaving it to eat from the vermin of the earth.
The great Companion Abu Hurayrah (literally “Father of the Kitten”) was so called because he used to love cats and keep them. He became well known by this name and people forgot his real name, until the scholars disputed concerning his real name and there were nearly thirty different opinions as to what it was. Ibn ‘Abd al-Barr said in al-Isi’ab: “The most correct view is that his name was ‘Abd al-Rahman ibn Sakhr but none of them disputed that he was Abu Hurayrah.”
Selling cats and dogs in Islam
It is permissible to keep cats but it is not permissible to buy or sell them; they may be given as gifts or given away. That is because of the hadith of Abu’l-Zubayr who said: “I asked Jabir about the price of dogs and cats. He said, ‘The Prophet forbade that.’” (Muslim)
Source: Islam Q&A
Almighty Allah knows best.