Peace in Europe could be at risk if Britain votes to leave the European Union, David Cameron has warned.
The UK has regretted "turning its back" on Europe in the past, the PM said, arguing the EU had "helped reconcile" countries and maintain peace.
Was leaving the union a "risk worth taking", Mr Cameron asked.
But ex-London mayor Boris Johnson hit back, saying the EU's "anti-democratic tendencies" were "a force for instability and alienation".
Mr Johnson also sparked criticism when he suggested the conflict in Ukraine was an example of "EU foreign policy-making on the hoof".
Former Swedish prime minister Carl Bildt, as well as the official Remain campaign, branded him an "apologist for Putin".
Mr Johnson called for an apology, saying the comments were "absolutely contemptible" and that he had repeatedly condemned Russia's actions in Ukraine.
- Follow the latest developments on BBC EU referendum live
- Reality check: Security and the EU
- The UK's EU vote: All you need to know
There are just over six weeks to go until the 23 June referendum which will decide whether Britain remains in or leaves the EU.
Why this issue matters What the leave and remain sides are saying about the UK's global role and defence in the #EUref campaignThe debate
- The EU’s role in foreign affairs has grown in recent years
- Its foreign policy is led by the High Representative for Foreign Affairs who is assisted by the European External Action Service
- Individual member states retain a veto on foreign policy proposals
Leave
- Membership of NATO and the UN Security Council are more important to Britain’s defence than the EU
- The EU interferes with defence procurement and wants to set up its own army
- Britain would have more influence on the world stage as an independent country
Remain
- UK needs to be in the EU helping to take big decisions, not sitting on the sidelines
- Leaving the EU would diminish Britain’s influence on the world stage
- Working with our closest neighbours to tackle shared threats has helped keep Britain safer
Despite his warning of the consequences of a vote to leave, Mr Cameron defended his decision to call the referendum, telling the BBC: "You shouldn't try to hold an independent sovereign nation in an organisation against its will."
His comments - and a rival speech from Mr Johnson - came as the referendum campaign intensifies, following last week's elections.
The PM, who was introduced by former Labour foreign secretary David Miliband, argued the EU - with Britain in it - had helped bring together countries that had been "at each others' throats for decades".
He warned the peace and stability Europe has enjoyed in recent years could not be guaranteed, saying leaving risked "the clock being turned back to an age of competing nationalism in Europe".
While Europe has largely been at peace since 1945, Mr Cameron said it was barely two decades since the Bosnian war while, more recently, Russia has been at war with Georgia and Ukraine.
"Can we be so sure that peace and stability on our continent are assured beyond any shadow of doubt? Is that a risk worth taking? I would never be so rash as to make that assumption," he said.
Mr Cameron argued "isolationism has never served this country well".
Analysis
Image copyright Getty ImagesBy BBC Political Editor Laura Kuenssberg
During the course of political campaigns the claims being made on different sides become more and more well, shall we say, stretchy.
It is certainly true that many security experts have gone on the record warning against what might happen. And nearly all of our international allies think that staying in the European Union is a safer option. The number of diplomatic cars clogging up the narrow streets around the British Museum this morning in London's Bloomsbury was a sure sign of that.
But the prime minister's klaxon this morning?
Remember less than three months ago he was still saying that he would be ready to lead us out of the EU if he didn't reform our relationship.
Unless you believe he would knowingly have risked plunging the country into a conflict, you'd be forgiven for at least sprinkling a little salt on his arguments this morning.
Read Laura's full analysis
Mr Cameron ranked 2016 alongside other major events in European history, including the Spanish Armada in 1588, the battles of Blenheim and Waterloo in 1704 and 1815 respectively, the two world wars, as well as the fall of the Berlin Wall.
"The truth is this: what happens in our neighbourhood matters to Britain," the PM added.
"That was true in 1914, in 1940 and in 1989. Or, you could add 1588, 1704 and 1815... And if things go wrong in Europe, let's not pretend we can be immune from the consequences."
Vote Leave said Nato, not the EU, kept the UK safe and accused Downing Street of "losing the plot".
It said: "During the renegotiation the PM said he 'ruled nothing out'. Now he thinks leaving the EU would lead to war. What changed?"
It pointed to analysis by the Historians for Britain group, which described the suggestion the EU had prevented wars as "groundless" and "historically illiterate".
In his own speech on Europe, Mr Johnson said the PM's argument "grossly underestimates the way Europe has changed" as well as the role of Nato.
He said the EU itself and its "anti-democratic tendencies" were in fact "a force for instability and alienation".
It comes after former MI6 boss Sir John Sawers warned leaving the EU would make the UK "less safe".
He said the UK would be shut out of decisions on the "crucial" issue of data sharing.
However, Justice Secretary Michael Gove - who backs the campaign for the UK to leave the EU - said Sir John was "flat wrong".
- Subscribe to the BBC News EU referendum email newsletter and get a weekly round-up of news, features and analysis on the campaign sent straight to your inbox.