In the canons of Fiqh and Fatawa, Fath Ul Qadeer, Al Bahr Ur Raaiq, Fatawa A’alamgiri, Haashiya Ash Shalbi Ala Tabyeen Ul Haqaaiq, Majma Ul Anhur, Al Muheet Al Burhani and Radd Ul Muhtaar Ala Durre Mukhtaar, etc. the following clarifications are mentioned about situations similar to IVF.
It is mentioned in Al Bahr Ur Raiq of ‘Allama Ibn Nujaim Misri (May Allah shower His mercy on him):
Translation: The claim that for paternity of a man to be established, it is not necessary that he should have intercourse, sometimes, a woman herself enters the semen of a man in her vagina and conceives, is true, but it happens very rarely. (Al Bahr Ur Raiq, Vol. 4, Pg. No. 263)
A similar clause is present in Fath Ul Qadeer, Pg. No. 315 and Tabyeen Ul Haqaaiq, Pg. No. 276.
The aforementioned clause shows that this case is rare, still if such a situation occurs that the woman enters the semen into her vagina then conception may occur without intercourse as well. In IVF, the sperm and the ovum are combined outside the body and then the embryo is put into the womb.
A similar clause is present in Fatawa A’alamgiri:
Translation: A person had coitus interruptus with his slave girl. She took the semen and stored it somewhere, put it into her vagina and conceived. In this case, in the opinion of Imam Azam Abu Hanifa (May Allah shower His mercy on him), the parentage of that child will be through that master and the slave girl will be declared his Umme Walad (a mother of his child). (Fatawa A’alamgiri, Vol. 4, Pg. No. 114.
This situation is also described in Radd Ul Muhtaar, Kitab Un Nikah, Bab Ul Iddah and Al Bahr Ur Raiq, Vol. 4, Pg. No. 452)
The same situation has been described by ‘Allama Abdur Rahman Bin Muhammad, famously known as Shaykhzada (May Allah shower His mercy on him) in Majma Ul Anhur and by Allama Mahmood Bin Ahmed (May Allah shower His mercy on him) in Al Muheet al Burhani.
As per the clauses and clarifications given by the Imams of the Ummah in the canons of Fiqh and Fatawa, IVF is inherently permissible, but to accomplish it, performance of some prohibited acts is inevitable and as such some cases of it are outright forbidden and some are Makruh (undesirable) with some conditions.