Abu Huraira reported: The Messenger of Allah, peace and blessings be upon him, said, “Do not swear an oath by your father, nor your mothers, nor by rivals to Allah. Do not swear an oath unless it is by Allah and you are honest.”
Source: Sunan Abī Dāwūd 3248
Grade: Sahih (authentic) according to Al-Albani
عَنْ أَبِي هُرَيْرَةَ قَالَ قَالَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ لَا تَحْلِفُوا بِآبَائِكُمْ وَلَا بِأُمَّهَاتِكُمْ وَلَا بِالْأَنْدَادِ وَلَا تَحْلِفُوا إِلَّا بِاللَّهِ وَلَا تَحْلِفُوا بِاللَّهِ إِلَّا وَأَنْتُمْ صَادِقُونَ
3248 سنن أبي داود كتاب الأيمان والنذور باب في كراهية الحلف بالآباء
3248 المحدث الألباني خلاصة حكم المحدث صحيح في صحيح أبي داود