Babies don't "inherit" immunity in the sense that it's passed down genetically. During the last three months of pregnancy, antibodies from the mother are passed to the unborn child through the placenta. The antibodies are what give them immunity. Also, after birth, breast feeding will similarly pass on antibodies from the mother to the child.
lc9984 t1_jaeh6mv wrote
Reply to ELI5 How do baby's inherit immunities if that doesn't effect your DNA by PartyTerm4817
Babies don't "inherit" immunity in the sense that it's passed down genetically. During the last three months of pregnancy, antibodies from the mother are passed to the unborn child through the placenta. The antibodies are what give them immunity. Also, after birth, breast feeding will similarly pass on antibodies from the mother to the child.