Praise be to Allah.
We put this question to Shaykh Muhammad ibn Saalih al-‘Uthaymeen (may Allaah preserve him), who answered as follows:Of course these are not his children.
Question: He knows that the sperm did not come from him.
Answer: They are not his children. Some scholars say that if a zaani claims his child as his own, the child may be named after him, but this is not his child. He is not like a zaani, because in the case of a zaani the sperm comes from him, but this sperm did not come from this man. He has to disown these children and give them to the government or do something with them (by putting them in a place where they will be taken care of or giving them to a charitable organization which will sponsor their upbringing).
Question: Shall we tell him, you should not call them after yourself (give them your name)?
Answer: Yes, (tell him) to disown them, and give them to the government, or let them stay with their mother, on the condition that they are not named after this man.Question: Does the hadeeth “the child is for the bed” apply in this case? Answer: No, it does not apply. [ends] We ask Allaah to keep us safe and sound. This is one of the (crimes) which modern civilization has committed against people’s lineages and honour, and one of the ways in which it has deceived people. Social disasters of this sort are the expected result of the sins of lying, forgery and deceit which this man has committed against his wife. How could he have done this thing, which is forbidden by sharee’ah, and which goes against the shar’i aims of protecting lineages and against his own manhood? This is a particularly ugly way of cooperating in sin and transgression and taking part in falsehood, on the part of the donor or vendor of the sperm, and the criminal doctor who agreed to do the operation. It is to Allaah that we complain when religion becomes a stranger in people’s lives and the immoral enemies of Islam prevail. And Allaah is the One Whose help we seek.