Aqiqah should be performed for a baby who has passed away whether, in the womb (exceeding 4 months) or before the 7th day of birth, as a sign of gratitude for being bestowed the opportunity to have an offspring even if for a short while. Its ruling is not sunnah unlike performing aqiqah on the 7th day of a child being born which is claimed as sunnah muakkad.