I have taken an oath of my friend, he said take oath of my life that you will quit smoking but somehow i couldn't manage to do that and after 2 months of oath i broke it by smoking a cigarette. So, i would like to know that is taking oath of a friend is valid and if it's valid then what should i do when i broke it.
All perfect praise be to Allah, The Lord of the Worlds. I testify that there is none worthy of worship except Allah, and that Muhammad, is His slave and Messenger.
You did wrong by swearing by the name of your friend or his life because it is impermissible to swear by other than Allah, The Exalted. The Prophet said: “Whoever has to take an oath should swear by Allah or remain silent.” [Muslim] Swearing by other than Allah, The Exalted, is a form of Shirk (polytheism). The Prophet said: “Whoever swears by other than Allah has committed disbelief or Shirk.” [Ahmad, Abu Daawood and At-Tirmithi]
However, you are not required to make expiation for breaking an oath because swearing by other than Allah does not count as a binding oath to begin with, and accordingly breaking it entails no expiation. Al-Mawsoo‘ah Al-Fiqhiyyah (The Kuwaiti Encyclopedia of Fiqh) reads: “There is no difference of opinion among Muslim jurists on the ruling that if a person swears by other than Allah, The Exalted, he is not liable for expiation should he break such an oath.” [End of Quote]
Allah knows best.
You can search for fatwa through many choices