When Rahma Abukar Ali boarded a migrant ship in Libya on August 22, she knew the trip would mark the start of something new and hopeful or bring an end to her life.

Nine months pregnant, Ali had spent the previous five months making her way from Somalia to the Libyan coast, trudging mile after mile through the searing Sahara Desert. Her only relief from walking came when she slept or was packed into trucks crowded with others fleeing the battle-scarred Horn of Africa.

"I was feeling dizzy; I was tired because of the long journey," she says. "But I could not deliver the baby in Libya, so when I boarded the boat, I was ready to die with my unborn child or make it to Europe."

Somali migrant mother Rahma Abukar Ali was pregnant with baby daughter, Sophia, when they boarded the boat (shown here) in Libya, and she gave birth on a German Navy vessel in the Mediterranean, a day after she was rescued from the boat. (A. Osman/VOA)

Ali made it to Europe, but only after giving birth on a German Navy vessel in the middle of the Mediterranean, a day after her rescue from the migrant boat.

Now, she and her baby daughter, Sophia, are living at a refugee center in a small German town near Düsseldorf, where she is awaiting a response to her application for asylum.

In a VOA interview last week, Ali said that she was excited to have completed her journey to Europe and that her seven other children in Mogadishu were relieved she'd made it.

She appealed to the German government to accept her refugee application and allow her family to leave Somalia as well.

"I want them now to join us here in Germany," she said. "They want to see their little Sophia."

Somali migrant mother Rahma Abukar Ali walks her baby daughter, Sophia, in a stroller at a refugee center in a small German town near Düsseldorf, where she is awaiting a response to her application for asylum, Oct. 2015. (A. Osman/VOA)

'Unbearable' journey

The 33-year-old Ali began her journey in March. She left behind the older children and their father in Mogadishu, capital of a nation that hasn't known any peace in a quarter century, a place where the lack of security and scarce jobs made life so unbearable that she decided to risk the dangerous journey to Europe.

"I dared it for the betterment of my family," Ali said.

But she also warned other pregnant women against trying to make the trip.

"It is unbearable and people should avoid it at all [costs]. Going through the Sahara is hard ... and the suffering that migrants are subjected to by the smugglers in Libya is harder," Ali said, allowing only that the smugglers were "not that harsh" on her because she was pregnant.

On the Libyan coast, Ali saw another pregnant woman, who was less fortunate.

She "died after delivering a baby as she was boarding a boat at the Libyan shore," Ali recalled. "Her baby also died instantly."

Only one other pregnant woman took the same journey, and she survived.

"We all risked this journey to run away from the sufferings we encountered in Libya and Somalia," she said, sighing.

Birth at sea

Ten hours after the boat sailed north from Libya, it was intercepted by a British vessel. The crew then transferred Ali and 453 other migrants to a German navy ship known as the Schleswig-Holstein.

Ships were patrolling the area under the European Union’s program to search and seize vessels suspected of smuggling people across the Mediterranean.

The EU expanded the program this year in the wake of criticism it was forcing migrants to risk their lives in unsafe, rickety boats. The U.N. refugee agency says more than 3,100 migrants have died in the Mediterranean this year. Another 643,000 have successfully made the crossing.

Ali went into labor after a day and night aboard the rescue vessel. Sophia likely was the first migrant baby to be born on a German frigate.

“Two doctors on the German ship helped me and took care of me to deliver the baby,” she said. “God saved me, and thanks to the government of Germany.”

The ship docked in Italy, where mother and baby were given postnatal care coastal town of Trapani.

Recovering

Now in Germany, Ali said that she and her daughter were doing fine, and that immigration officers have told her Sophia is a "German citizen," if only because she was born on a ship sailing under their flag.

Baby Sophia's future is a bright one, Ali said.

“I am hopeful my daughter would get the full citizenship and will have a better life in Germany.”