WELLINGTON, NEW ZEALAND (NYTIMES) - They arrived in New Zealand from across the Middle East and Asia, forming a tightly bound community of Muslims reaching back to the mid-19th century who in recent years went there to attend universities, open restaurants or escape wars in Syria, Afghanistan and Iraq.
It felt as if everyone knew everyone. Mosques were not for Pakistanis or Somalis or Bangladeshis, but for anyone in town, residents and visitors alike, residents said.
And so, when a gunman stormed two mosques in the city of Christchurch during Friday prayers, killing 49 people, the terror rippled through New Zealand's nearly 50,000 Muslims and beyond, reaching into homes throughout the Middle East, Asia and Oceania.
Families scrambled for visas so that they could race to the bed sides of the injured. They posted lists of the missing that went on and on. And in New Zealand, they just tried to get someone to answer their calls.
"Nobody's answering their phones," said Ms Nasreen Hanif, a spokeswoman for the Islamic Women's Council of New Zealand, which is based in Auckland, an 85-minute flight from Christchurch.
"We don't know if they're at the hospital or out of reach. Some have posted that they are safe, but others have not."
She said one set of parents was waiting to hear from their son, who had not been seen.
"They were supposed to have lunch with him after prayers," she said.
The names of victims have not been released.
Late on Friday, bodies remained in the two mosques, behind a police cordon, and dozens of people were being treated at Christchurch Hospital.
Prime Minister Jacinda Ardern branded the killings a "well-planned" terrorist attack.
Muslim leaders in New Zealand said mosques across the country, including the two that were attacked, tended to attract a multi-ethnic group of worshippers. And those injured and killed appeared to reflect their diverse congregations.
At least one Palestinian was killed and several others were injured in the attacks, said the Palestine Liberation Organisation's ambassador to Australia and New Zealand, Mr Izzat Abdulhadi.
Two Malaysians were being treated for injuries, the Malaysian Ministry of Foreign Affairs said. And nine people of Indian nationality or origin were missing, Mr Sanjiv Kohli, the High Commissioner of India to New Zealand, said on Twitter.
Syrian Solidarity New Zealand, a group that describes itself as a non-governmental organisation of Syrians and their supporters in the country, said in a statement on its Facebook page that "Syrian refugees, including children, have been shot today".
An official from the group, Mr Ali Akil, told a local news outlet, Newshub, that a father was among those killed, and one family had a child missing and another in serious condition in the hospital.
"They escaped death and torture in Syria, to come to New Zealand, and be killed here," Mr Akil told Newshub.
News of the attacks crisscrossed the world and sent people searching frantically for word of their friends and relatives.
One of those who was shot, Mr Ahmed Jehangir, is a 12-year resident of New Zealand who owns a restaurant there offering cuisine from Hyderabad, the city in India where his family is from, according to a Hyderabad politician on Twitter and local news reports.
A brother of the man told The News Minute, an Indian news site, that two of Mr Jehangir's friends were killed and he was "struggling for his life".
Mr Jehangir's family, starved for information and desperate to help Mr Jehangir's wife and two small children, were asking for help securing a visa to New Zealand as quickly as possible.
Another family in Hyderabad was also waiting for word about a relative: Mr Farhaj Ashan, who had last contacted before leaving for Al Noor Mosque in Christchurch, The News Minute reported.
A software engineer living in Christchurch with his wife, three-year-old daughter and six-month-old son, Mr Ashan had gone to New Zealand for a master's degree at the University of Auckland in 2010 and stayed, the news site reported.
"Everyone has come back, but not my son," Mr Ashan's father, Mr Mohammad Sayeeduddin, 68, told The News Minute.
A site managed by the International Committee of the Red Cross listed dozens of people who had been recorded as missing, including people from Egypt, Syria, India, Kuwait, Palestine, Jordan, Afghanistan, Pakistan and Somalia.
The Pakistan Association of New Zealand circulated on its Facebook page a health form to be used by people looking for loved ones, asking for details like eye colour and any distinguishing birthmarks or scars.
The group listed six members of the Pakistani community it said were missing, beseeching people to get in contact if they knew of the missing people's whereabouts.
For Muslims in New Zealand and abroad, the massacre drew both sadness and outrage - it was a crime and a tragedy, but also, in the eyes of many, a brazen act of hatred borne from years of anti-Muslim sentiment.
Officials in several Muslim-majority countries - including Indonesia, Malaysia and Pakistan - condemned the attacks as a byproduct of racist and religious prejudice.
Indonesian Foreign Minister Retno Marsudi emphasised the horror of the shootings occurring during Friday prayers.
A spokesman for President Recep Tayyip Erdogan of Turkey called the attacks "racist and fascist".
"This cowardly act shows how anti-Muslim rhetoric and hatred leads to murderous acts," the spokesman, Mr Ibrahim Kalin, wrote on Twitter. "The world must break its silence over Islamophobic hatred."
Muslim leaders across New Zealand, however, stressed that the attacks were out of character for the country, a place many of them associated with peace.
"Muslims have been in New Zealand for a long time, and Muslims have never had any issues in New Zealand," said Mr Ibrar Sheikh, the secretary of a mosque in Auckland, Al Mustafa Jamia Masjid.
"Just because one or two individuals have taken this stand, it doesn't mean there is an attack on people living in New Zealand."
He said that the deaths would affect Muslims across the country. "Everybody knew each other," he said, adding that he had been unable to contact friends who had worshipped at the Christchurch mosques on Friday.
The two mosques attacked in Christchurch were, like most mosques in New Zealand, "a United Nations" of ethnicities, Mr Sheikh said, rather than hosting worshippers from any particular ethnic group.
The first Muslims to arrive in New Zealand, a British-Indian family, landed in Christchurch in 1854.
Larger-scale Muslim immigration began in the 1970s, with the arrival of families and students from the Pacific islands. The region of Canterbury, which includes Christchurch, has been an area of steady growth.
Mr Abdullah Drury, a scholar who completed a history of Muslim migration in New Zealand two years ago, said the Muslim population in Canterbury grew enough that by 1977, a formal association could be registered and organised.
The group set up the first Muslim place of prayer on New Zealand's South Island in Christchurch three years later.
Muslim immigration accelerated in the 1990s and 2000s with arrivals from war-torn countries like Iraq and Afghanistan.
The 2013 census counted a national population of more than 4.2 million people, including more than 46,000 people who identified as Muslim, up nearly 30 per cent from 2006.
Research shows that the majority of Muslims in New Zealand are Sunni, with a large Shi'ite minority and some Ahmadi Muslims.
Now, Ms Hanif said, a close community must become even closer: Both mosques that were attacked on Friday had already reached out to ask for help with funeral arrangements.
Ms Ardern, the Prime Minister, noted that many of the victims were immigrants.
"For many, this may not have been the place they were born," she said. "For many, New Zealand was their choice, the place that they chose to come to and committed themselves to, the place they chose to raise their families."
Ms Ardern said New Zealand was a haven from hatred, racism or extremism, and that is why it had become a target.
"We were chosen for the very fact that we are none of these things," she said. "Because we represent diversity, kindness, compassion, a home for those who share our values, refuge for those who need it. Those values will not and cannot be shaken by this attack."