President Donald Trump tweeted his condolences Friday morning over the mass shootings that killed 49 people at two mosques in Christchurch, New Zealand.

"My warmest sympathy and best wishes goes out to the people of New Zealand after the horrible massacre in the Mosques. 49 innocent people have so senselessly died, with so many more seriously injured," Trump wrote. "The U.S. stands by New Zealand for anything we can do. God bless all!"

TRUMP TWEET

The White House also weighed in on Friday and said the U.S. "strongly condemns" the attack.

"Our thoughts and prayers are with the victims and their families. We stand in solidarity with the people of New Zealand and their government against this vicious act of hate," press secretary Sarah Huckabee Sanders said.

A man in his late 20s was charged with murder, and New Zealand Police Commissioner Mike Bush said four people had been taken into custody, three men and one woman. Multiple explosives had been found attached to vehicles.

The nation's prime minister, Jacinda Ardern, denounced the massacre as a "terrorist attack."

"This is one of New Zealand's darkest days," Ardern said. "Clearly what has happened here is an extraordinary and unprecedented act of violence."

A live 17-minute video that appeared to be taken by the gunman was posted to social media the day of the attack. Facebook and Twitter took down the pages linked to the shooter, but the live stream was spread across the internet, creating new questions about how tech companies can manage harmful content.

Other global leaders have also offered support to New Zealand after the attacks.

British Prime Minister Theresa May tweeted, "On behalf of the UK, my deepest condolences to the people of New Zealand after the horrifying terrorist attack in Christchurch."

French President Emmanuel Macron added, "All our thoughts for the victims of heinous crimes against the mosques of Christchurch in New Zealand and for their loved ones."

The U.S. and New Zealand are partners through the "Five Eyes" intelligence-sharing alliance, along with Australia, Canada and the United Kingdom.

— CNBC's Everett Rosenfeld contributed to this report.