Not long ago, we were excitedly anticipating the birth of a child. It seemed like the pregnancy was going well. All of the tests came back clear, and the baby was developing properly. Then, suddenly everything changed. On what we thought was going to be a routine checkup at the doctor, we discovered that the baby’s heart was no longer beating.

Although this was week 19 of the pregnancy, It became clear to us that this baby was not meant to be bornthe doctors told us that the baby passed away at week 16, three weeks beforehand. Week 16 is already in the second trimester, after the uncertainty of the first trimester, in which most miscarriages occur. Once the second trimester arrives, most women relax in the knowledge that their baby is most likely going to make it out into the world. I tend to be more anxious than most, but even I breathed a sigh of relief as the first trimester came to an end. The nausea, fatigue and worry were starting to decline, and we could start to enjoy the rest of the pregnancy. The miscarriage came as a terrible shock.

The next day passed in a blur of tears and grief. We had already started planning for when the baby would be born. We had even picked out a name. And that sudden loss—the sudden ending of our hopes and dreams for having this little girl in our lives—was devastating.

During the sleepless night that followed, I searched for Jewish thoughts and sources that could help me find meaning in the loss. What I found was very helpful, and I’d like to share the ideas that resonated with me in the hope that it will help others.

1. Perhaps the most comforting thing that I read was that there exists a world of souls. Each soul must come down into the world, its mission being to bring the world closer to Redemption (Yevamot 62a). But some souls are so holy that they would suffer terribly in this world. G‑d grants them that they can come down only partially. He chooses a couple to host this soul for its brief stay on earth, and then the soul departs, having left its mark on the world via the parents who hosted it.

2. G‑d loves us and always wants what is best for us. Even when life’s events devastate us, G‑d is there by our side, picking us up and helping us to go on and to heal. As we read in Psalms (34:29) “The L-rd is close to the brokenhearted; those crushed in spirit He delivers.”

3. It is not our place to understand why things happen. It is our mission to deal with what comes our way in the sure knowledge that G‑d knows what He is doing.

4. “We can trust in G‑d that everything will work out for the best in the end.” The late Rabbi Abraham J. Twerski relateed a story of one of his patients, a woman who suffered severely with anxiety. This woman was a huge fan of the Jets and once asked her friend to record the game for her while she was out of town. When the friend handed over the tape, she mentioned that the Jets had won. The woman began watching the tape and was horrified at the Jets’ poor performance, but knowing that they ultimately won allowed her to keep her anxiety in check despite what looked likely to end in overwhelming defeat. Knowing that G‑d is in charge of our lives and wants what is best for us allows us to tame our anxieties and let the game play out, understanding that ultimately it will all be OK.

Putting these ideas together, Even when life’s events devastate us, G‑d is there by our sideit became clear to us that this baby was not meant to be born. It is not because of something we did or did not do. It is not a punishment. We were given the honor of hosting her for 16 weeks and then G‑d took her back. By learning from her brief existence to better ourselves, we can give her a legacy and help her fulfill her mission of improving the world.

The name we had already picked out for our baby girl was Yael Roni. Yael (the name of a brave woman, whose swift actions saved the Jewish people) symbolizes courage, while Roni (whose root word means “rejoice”) symbolizes encouragement and hope for the future. Our experience can inspire us to muster up the strength needed to get through the hard times, to face our greatest fears and to always have faith in G‑d that it will all work out in the end.

Please G‑d, we will merit future healthy births. But going through the events of the last week has changed my perspective entirely. No longer will I be fearful each week of losing a pregnancy. From here on in, I hope, in memory of my lost baby, to treasure each week of pregnancy as a week of privilege in hosting a holy soul in this world. My baby’s life span was heartbreakingly short, but we hope she can inspire us, and others, to get through life’s hardest challenges.