By Sabine Siebold and Robin Emmott
MADRID (Reuters) - NATO invited Sweden and Finland on Wednesday to join the military alliance in one of the biggest shifts in European security in decades after Russia's invasion of Ukraine pushed Helsinki and Stockholm to drop their traditional of neutrality.
NATO's 30 allies took the decision at their summit in Madrid and also agreed to formally treat Russia as the "most significant and direct threat to the allies' security", according to a summit statement.
"Today, we have decided to invite Finland and Sweden to become members of NATO," NATO leaders said in their declaration, after Turkey lifted a veto on Finland and Sweden joining.
Ratification in allied parliaments is likely to take up to a year, but once it is done, Finland and Sweden will be covered by NATO's Article 5 collective defence clause, putting them under the United States' protective nuclear umbrella.
"We will make sure we are able to protect all allies, including Finland and Sweden," Stoltenberg said.
In the meantime, the allies are set to increase their troop presence in the Nordic region, holding more military exercises and naval patrols in the Baltic Sea to reassure Sweden and Finland.
After four hours of talks in Madrid on Tuesday, Turkish President Tayyip Erdogan agreed with his Finnish and Swedish counterparts a series of security measures to allow the two Nordic countries to overcome the Turkish veto that Ankara imposed in May due to its concerns about terrorism.
The North Atlantic Treaty Organisation was founded in 1949 to defend against the Soviet threat. Russia's Feb. 24 invasion of Ukraine gave the organisation a new impetus after failures in Afghanistan and internal discord during the era of former U.S. President Donald Trump.
"We are sending a strong message to (Russian President Vladimir) Putin: 'you will not win'," Spanish Prime Minister Pedro Sanchez said in a speech.
Allies also agreed on NATO's first new strategic concept - its master planning document - in a decade. Russia, previously classed as a strategic partner of NATO, is now identified as NATO's main threat.
Russia's invasion of Ukraine is "a direct threat to our Western way of life," Belgian Prime Minister Alexander de Croo added, citing the wider impact of the war, such as rising energy and food prices.
The planning document also cited China as a challenge for the first time, setting the stage for the 30 allies to plan to handle Beijing's transformation from a benign trading partner to a fast-growing competitor from the Arctic to cyberspace.
Unlike Russia, whose war in Ukraine has raised serious concerns in the Baltics of an attack on NATO territory, China is not an adversary, NATO leaders said. But Stoltenberg has repeatedly called on Beijing to condemn Russia's invasion of Ukraine, which Moscow says is a "special operation".
At the summit, NATO agreed a longer-term support package for Ukraine, in addition to the billions of dollars already pledged in weapons and financial support.
German Chancellor Olaf Scholz said that arms would continue to be supplied to Kyiv, which seeks help to overpower Russian artillery, particularly in eastern Ukraine, where Russia is slowly advancing in a grinding war of attrition.
"The message is: We will continue to do so - and to do this intensively - for as long as it is necessary to enable Ukraine to defend itself," Scholz said.
The Western alliance is also in agreement that big allies such as the United States, Germany, Britain and Canada pre-assign troops, weapons and equipment to the Baltics and intensify training exercises. NATO is also aiming to have as many as 300,000 troops ready for deployment in case of conflict, part of an enlarged NATO response force.
Russia is achieving the opposite of what Putin sought when he launched his war in Ukraine in part to counter the expansion of NATO, Western leaders say.
Both Finland, which has a 1,300 km (810 mile) border with Russia, and Sweden, home of the founder of the Nobel Peace Prize, are now set to bring well-trained militaries into the NATO, aimed at giving the alliance Baltic Sea superiority.
"One of the most important messages from President Putin ... was that he was against any further NATO enlargement," Stoltenberg said on Tuesday evening. "He wanted less NATO. Now President Putin is getting more NATO on his borders."
(Additional reporting by Aislinn Laing, Belen Carreno, Humeyra Pamuk, Andrea Shalal, writing by Robin Emmott; Editing by Frank Jack Daniel)