Treatment with forbidden things is forbidden
➊ Hazrat Tariq bin Suwayd al-Ju’fi (may Allah be pleased with him) asked the Prophet ﷺ about making medicine from wine, so he ﷺ said:
إنه ليس بدواء ولكنه داء
“It is not a medicine, rather it is a disease.”
[Muslim: 1984, Kitab al-Ashriba: Bab Tahrim al-Tadawi bi al-Khamr wa Bayan Annaha Laysat bi Dawa’, Ahmad: 311/4, Tirmidhi: 2046, Abu Dawud: 3873]
➋ It is narrated from Hazrat Abu Hurairah (may Allah be pleased with him) that:
أن النبى صلى الله عليه وسلم نهي عن الدواء المخبيث
“The Prophet ﷺ forbade impure (khabith) medicine.”
[Sahih: Sahih Ibn Majah: 2785, Kitab al-Tibb: Bab al-Nahy an al-Dawa’ al-Khabith, Ibn Majah: 3459, Abu Dawud: 3870, Tirmidhi: 2045, Ahmad: 305/2]
➌ Hazrat Ibn Mas’ud (may Allah be pleased with him) said:
إن الله لم يجعل شفائكم فيما حرم عليكم
“Allah the Exalted has not placed your cure in what is forbidden to you.”
[Bukhari: before hadith 5614, Kitab al-Ashriba: Bab Sharab al-Halwa’ wa al-‘Asal, Ibn Abi Shaybah: 38/5, Fath al-Bari: 210/11]
It should be clear that these hadiths do not contradict those hadiths in which it is mentioned that the Messenger of Allah ﷺ had camels’ urine used as medicine.
[Bukhari: 5686, Kitab al-Tibb: Bab al-Dawa’ bi Abwal al-Ibil, Muslim: 1671, Abu Dawud: 4364, Nasa’i: 93/7, Tirmidhi: 1845, Ibn Majah: 2587, Ahmad: 107/3]
This is because camels’ urine is neither impure nor forbidden. And even if it were hypothetically accepted as forbidden, it is still possible to reconcile them by applying the general to the specific (that is, using forbidden things as medicine is forbidden, but camel urine is an exception to this because it is specific).
[For further detail see: Nayl al-Awtar: 288/5, al-Rawdah al-Nadiyyah: 492/2]