Sahih al-Bukhari, Book 64, Hadith 53 (Bukhari 3837)

Narrated Ibn `Abbas:

Abu Talha, a companion of Allah's Messenger (ﷺ) and one of those who fought at Badr together with Allah's Apostle told me that Allah's Messenger (ﷺ) said. "Angels do not enter a house in which there is a dog or a picture" He meant the images of creatures that have souls.