To offer another perspective. . . .
Rh factor is a factor found in blood. It makes up one part of your blood type. Rh+ individuals have Rh factor. Rh- individuals do not have Rh factor, and make antibodies against it when exposed to it.
Rh factor is dominant in inerheritance. Thus, an Rh- woman with an Rh+ partner will have an Rh+ baby if her partner is homozygous (++) and has a 50% chance of having an Rh+ baby if her partner is heterozygous (+-).
Rh- moms will make antibodies against Rhesus factor once exposed. These antibodies can attack the blood cells of an Rh+ fetus in subsequent pregnancies. While blood does not typically cross the placental barrier, antibodies do.
Typically, maternal exposure to fetal blood does not occur until delivery, and sometimes not even then. Exposure can also occur in the event of a serious hemmorage. For example, if a pregnant woman is traumatically injured (for example, in a car accident) placental hemmorhage may cause maternal-fetal blood mixing.
In the past, Rh- moms with Rh+ partners (especially Rh+ homozygous partners) lost babies to a condition known as Rh disease. Their first children were usually healthy, but subsequent babies were brain damaged because of hemmorhages, or are stillborn. This was caused by the destruction of the fetuses' Rh+ red blood cells my antibodies from the mother's immune system. WHen the red blood cells were destroyed, oxygen could not be transported to the fetuses' cells, causing death of tissue.
Rhogam and similar products provide antibodies that are intended to prevent this. The antibodies in the shot respond to any blood mixing. Because the "foreign" antibodies (from the Rhogam) are available, the mother's body does not manufacture its own antibodies. Because the foreign antibodies are limited, they cannot cause the same kind of large-scale damage to the fetus as the mother's unchecked immune response.
Typically, Rhogam is given to mothers shortly after birth to protect subsequent pregnancies. Many health care providers in the US also give Rhogam to pregnant women at 28 weeks to protect against immune responses that may occur as a result of unforseeable accidents. Rhogam is also often administered to RH- women who have abortions or miscarriages, to protect future pregnancies. Occasionally, Rhogam is given to Rh- female babies with Rh+ moms, if there has been significant maternal hemmorhage during delivery.
Rhogam does not completely eliminate the risk of Rh disease. It does provide significant protection against it. It no longer contains mercury. According to the CDC, there has only been one case of suspected HIV transmission from Rhogam. The suspected case turned out to be the result of exposure through other behavioral factors. Rhogam is intensively screened. It is possible that some disease somewhere will someday turn out to be or to have been transmitted by Rhogam. No such disease has yet been discovered.
IMO, this medication is safe, especially if only used at need, instead of just injected willy-nilly at 28 and 40 weeks. For many women, it's not necessary. If you have an Rh+ baby or a placental hemmorhage, you can get it then.