Leaders from the group of leading industrial nations, the G7, have called on internet giants to crack down on extremist content.
They warned internet service providers and social media companies to "substantially increase" their efforts.
But the summit in Taormina, Sicily, failed to agree on climate change.
US President Donald Trump, attending his first such summit, held off from endorsing the 2015 deal on reducing greenhouse gas emissions.
Separately, Mr Trump and UK Prime Minister Theresa May reaffirmed plans to boost trade, including a post-Brexit trade deal.
Mr Trump has welcomed the UK's vote to leave the European Union (EU).
Mrs May was also attending her first G7 summit, as were Italian Prime Minister Paolo Gentiloni and French President Emmanuel Macron.
The G7 consists of Canada, France, Germany, Italy, Japan, the UK and the US, while the EU also has representatives present.
Leaders 'united' in fight against terrorism
"We showed our united commitment and our determination to continue and to strengthen our fight against terrorism," said Mr Gentiloni.
The leaders signed a document saying more should be done by internet companies to identify and remove extremist material.
The leaders also voiced solidarity with the UK after Monday's bombing in Manchester in which 22 people, including children, were killed.
"We agreed the threat from Daesh [the Islamic State group] is evolving rather than disappearing," Mrs May said.
"As they lose ground in Iraq and Syria, foreign fighters are returning and the group's hateful ideology is spreading online. Make no mistake, the fight is moving from the battlefield to the internet."
Question of Paris climate accord 'still hanging'
"The question of the Paris climate accord is still hanging," said Mr Gentiloni.
German Chancellor Angela Merkel said the discussions with Mr Trump had been "intensive".
"The United States made clear that it has not yet made its decision and will not do so here, but rather will continue to work on this," she said.
President Trump, who once dismissed global warming as a "hoax", has previously threatened to pull out of the Paris agreement.
'Productive' discussions on EU - UK trade
According to the French news agency AFP, President Macron "snubbed" the British prime minister when they held their first official talks on the sidelines of the summit.
Mrs May told him that the UK and the 27 EU member states should be discussing their future relationship at the same time as discussing the terms of the UK's withdrawal, a Downing Street spokesman said.
However, a source in the French delegation said Mr Macron had repeated the EU's position that the terms of the divorce must be agreed first.
Mrs May later told reporters she had had a "very good and productive discussion" with Mr Macron.
Mr Gentiloni said progress on trade had been made but the wording of the final communique still needed to be worked out.
"But it seems to me the direct discussions today have produced common positions that we can work on," he added.
There has been concern that the US president might promote a protectionist agenda.
German weekly Der Spiegel quoted Mr Trump as saying in a meeting with European Commission President Jean-Claude Juncker on Thursday that Germans were "very bad" regarding car exports to the US.
During his election campaign last year, Mr Trump threatened customs duties in retaliation for Germany's trade surplus with the US, saying it owed "vast sums of money" to the US and Nato.
Uncertainty over Russian sanctions
There has been uncertainty over Mr Trump's position on sanctions imposed on Russia in response to its actions in Ukraine.
However, White House economic adviser Gary Cohn said at the summit on Friday: "We're not lowering our sanctions on Russia. If anything we would look to get tougher on Russia."
The US president and Japanese Prime Minister Shinzo Abe discussed the nuclear and missile threat from North Korea.
They agreed to "enhance sanctions on North Korea, including by identifying and sanctioning entities that support North Korea's ballistic missile and nuclear programmes", the White House said.
On Saturday, the second and final day of the summit, the leaders are expected to discuss human mobility, food security and gender equality.
Thousands of people are expected to join a protest march against the summit near Taormina.
During the talks, Melania Trump and other spouses toured Sicily by helicopter, taking in Mount Etna and visiting the nearby town of Catania.
According to the Spanish news agency Efe, Mrs Trump flew separately from the others for security reasons.