Sunan Abi Dawud, Book 40, Hadith 76 (Abu Dawud 4428)

Narrated Abdullah ibn Abbas:

Ma'iz ibn Malik came to the Prophet (ﷺ) and admitted fornication twice. But he drove him away. He then came and admitted fornication twice. But he drove him away. He then came and admitted fornication twice. He (the Prophet) said: You have testified to yourself four times. Take him away and stone him to death.