Is It Obligatory to Take a Loan to Offer Udhyah?
Question

Is it obligatory to take out a loan in order to buy the udhiyah?
Praise be to Allah.Is udhiyh compulsory? 
In the answer to question no. 36432  we stated that the scholars differed concerning the ruling on udhiyah and whether it is obligatory or mustahabb. 
Shaykh Ibn Baz (may Allah have mercy on him) said:  
“There is nothing in the Shar’i evidence to indicate that it is obligatory. The view that it is obligatory is a weak view.” (Majmu’ Fatawa Ibn Baz, 18/36)
Moreover, those who say that udhiyah is obligatory state that being rich is a condition of it being obligatory.  (See Hashiyat Ibn ‘Abidin, 9/452) 
Is it obligatory to take a loan to offer udhyah?
According to both opinions – the view that udhiyah is obligatory and the view that it is mustahabb – there is no need to take out a loan in order to buy the sacrificial animal, because it is not obligatory for one who is not rich, according to scholarly consensus. 
Is it recommended to take a loan to offer udhiyah?
Then there remains the question: is it mustahabb to take out a loan or not? 
The answer is that it is mustahabb to take out a loan if there is the hope that one can pay it back , such as if a person has a job and takes out a loan until he gets his salary at the end of the month. But if there is no hope of paying it off, then it is better not to take out a loan, because then he is taking on a commitment for something that he is not obliged to do. 
Shaykh al-Islam Ibn Taymiyah (may Allah have mercy on him) was asked about a person who is not able to offer the udhiyah – should he take out a loan? 
He replied: 
“If he can repay and he takes out a loan so that he can offer a sacrifice, that is good, but he is not obliged to do that.” (Majmu’ al-Fatawa, 26/305) 
However, Ibn Taymiyah (may Allah have mercy on him) was of the view that udhiyah is obligatory. 
Shaykh Ibn Baz (may Allah have mercy on him) was asked: Is the sacrifice obligatory for one who cannot afford it? Is it permissible to buy the sacrifice on credit until a person gets his salary?  
He replied: 
“The sacrifice (udhiyah ) is Sunnah and is not obligatory… there is no sin on a Muslim taking out a loan to offer the sacrifice if he is able to repay it.” (Fatawa Ibn Baz, 1/37)
And Allah knows best.