At least 42 people died and 39 were injured in the Friday incident, the United Nations' refugee agency said. Some 160 people reportedly were on board, according to the International Organization for Migration, or IOM.
Many of the victims were Somalis, and the Somali Foreign Ministry tweeted, "It is very sad to target a boat carrying Somali migrants."
"We wish Allah's mercy upon those who lost their lives, speedy recovery to the wounded," Somali Foreign Minister Abdusalam Omer said on Twitter.
The UN High Commission for Refugees, UNHCR, in Yemen worked Saturday to provide aid to those who made it to shore.
"We are providing medical support, food, financial and material assistance to survivors," the agency said on Twitter. "Other survivors are being screened by authorities in temporary custody with assurances they will soon be released."
Authorities haven't yet determined who was responsible for the attack. Witnesses have given conflicting accounts of whether a helicopter or a motorized military vessel opened fire on the boat, according to the IOM.
The Somali Foreign Ministry urged its partners in the Saudi-led coalition to investigate what it labeled as a raid Friday on the boat.
"Those injured are receiving treatment in hospitals and are quite shaken," UNHCR Yemen said of those who survived the boat attack. "Our teams are visiting them and providing them with urgent support."
The ongoing conflict means medical supplies to treat survivors are limited, the agency's spokeswoman in Yemen, Shabia Mantoo, told CNN Saturday.
UNHCR also said it was "working with partners to identify and ensure dignified and respectful arrangements" for those who were killed.
UN: En route to Sudan
The incident took place off the coast of the western province of Hudaydah. The refugees were crossing the Red Sea en route to Sudan, the UNHCR said Friday.
The attack took place in a "military area," the Somali general consul in Yemen, Ahmed Abdi Hassan, told CNN said.
Dozens were missing shortly after the attack, while others were treated at nearby hospitals, IOM spokesman Joel Millman said.
The precise number of those who were Somali is not yet clear, Hassan said.
The UNHCR was working with authorities to determine where the Somali refugees would go next, with the main priority to make sure they would get proper treatment, both physically and psychologically, Mantoo said.
Yemen has been in the grip of civil war since March 2015, when Houthi rebels -- a minority Shia group from the northern part of country -- drove out the US-backed government led by President Abdu Rabbu Mansour Hadi and took over the capital, Sanaa.
The crisis quickly escalated into a multi-sided war, which allowed al Qaeda and ISIS -- other enemies of the Houthis -- to grow stronger amid the chaos. The Houthis are backed by Iran, while a coalition led by neighboring Saudi Arabia supports Hadi's government.
"As conditions in Yemen deteriorate as a result of the ongoing conflict and humanitarian crisis, refugees and asylum seekers are increasingly fleeing onwards, following established migratory routes, including across the Red Sea to Sudan with the intention of heading onwards to Europe," the UN refugee group said in a statement
"This tragic incident is the latest in which innocent civilians, including Yemenis, refugees, asylum seekers and migrants, continue to suffer and disproportionately bear the brunt of the conflict in Yemen," it said.
According to a UNHCR tweet, "Yemen is host to almost 280,000 refugees, of which more than 255,000 are from Somalia."
In February, the organization launched a campaign aimed at spreading awareness about the dangers of crossing the Gulf of Aden and Red Sea from the African continent to war-stricken Yemen.