BRUSSELS (AP) — Finland joined the NATO military alliance Tuesday, dealing a major blow to Russian President Vladimir Putin with a historic realignment of Europe's post-Cold War security landscape triggered by Moscow’s invasion of Ukraine.

The Nordic country's membership doubles Russia’s border with the world’s biggest security alliance. , but its leaders signaled they wanted to join NATO after Moscow's invasion of Ukraine sent a shiver of fear through its neighbors.

“The era of nonalignment in our history has come to an end -– a new era begins,” President Sauli Niinistö said before his country’s blue-and-white flag was raised outside NATO headquarters. A short distance away, outside the security fence, a few dozen people wrapped in flags of their own chanted, “Ukraine needs NATO.”

In praising Finland's membership, U.S. President Joe Biden noted it came on the 74th anniversary of the signing of NATO's founding treaty on April 4, 1949.

“When Putin launched his brutal war of aggression against the people of Ukraine, he thought he could divide Europe and NATO. He was wrong,” Biden said in a statement. “Today, we are more united than ever. And together — strengthened by our newest ally, Finland — we will continue to preserve transatlantic security, defend every inch of NATO territory, and meet any and all challenges we face.”

The move is a strategic and political setback for Putin, who has long complained about NATO’s expansion toward Russia and partly used that as a justification for the invasion.

“I’m tempted to say this is maybe the one thing that we can thank Mr. Putin for because he once again here precipitated something he claims to want to prevent by Russia’s aggression, causing many countries to believe that they have to do more to look out for their own defense and to make sure that they can deter possible Russian aggression going forward,” U.S. Secretary of State Antony Blinken said before accepting the documents that made Finland’s membership official.

The U.S. State Department is the repository of NATO texts concerning membership.

Ukrainian President Volodymyr Zelenskyy sent his congratulations to Finland, writing on Telegram that “amid Russian aggression, the Alliance became the only effective guarantee of security in the region.”

Russia warned it would be forced to take “retaliatory measures” to address what it called security threats created by Finland’s membership. It had also warned it would bolster forces near Finland if NATO sends any additional troops or equipment to what is its 31st member country.

The alliance says it poses no threat to Moscow.

Alarmed by , Finland, which shares a 1,340 kilometer (832 mile) border with Russia, applied to join in May, seeking protection under the organization’s security umbrella.

“Russia tried to create a sphere around them and, well, we are not a sphere. I’m sure that Finns themselves feel more secure, that we are living in a more stable world,” Niinisto said.

Neighboring Sweden, which has avoided military alliances for more than 200 years, has also applied. But have delayed the process.

Niinisto said Finland’s membership "is not complete without that of Sweden. The persistent efforts for a rapid Swedish membership continue.“ Finland even gave its ratification of Sweden's application to Blinken as it joined.

In Stockholm, Swedish Defense Minister Pål Jonson congratulated Finland and said he believed it would improve Sweden’s security but added that “it’s no secret that we would like to have concluded it hand-in-hand.”

Earlier, Russia's Foreign Ministry said Moscow "will be forced to take military-technical and other retaliatory measures to counter the threats to our national security arising from Finland’s accession to NATO.”

It said Finland's move marks "a fundamental change in the situation in Northern Europe, which had previously been one of the most stable regions in the world.”

Kremlin spokesman Dmitry Peskov said Finland’s membership reflects the alliance’s anti-Russian course and warned that Moscow will respond depending on what weapons NATO allies place there. But he also sought to play down the impact, noting that Russia has no territorial disputes with Finland.

It's not clear what additional military resources Russia could send to the Finnish border. Moscow has deployed the bulk of its most capable military units to Ukraine.

NATO Secretary-General Jens Stoltenberg said no more troops would be sent to Finland unless it asked for help.

The country is now protected by what Stoltenberg called NATO's “iron-clad security guarantee,” under which all member countries vow to come to the defense of any ally that comes under attack.

But Stoltenberg refused to rule out the possibility of holding more military exercises there and said that NATO would not allow Russia’s demands to dictate the organization’s decisions.

“We are constantly assessing our posture, our presence. We have more exercises, we have more presence, also in the Nordic area,” he said.

In 1939 and 1940, Finland’s tiny, ill-equipped forces fought in what became known as the Winter War against the Soviet Union. Over an exceptionally cold winter, Finnish fighters, sometimes cloaked in white bedsheets for camouflage and typically moving unseen on foot, snowshoes and skis, lost some territory to Moscow but forced out the invaders.

Finland says it can muster a 280,000-strong fighting force, built on near-universal male conscription and a large, well-trained reserve, equipped with modern artillery, warplanes and tanks. The country of 5.5 million joined the European Union in 1995,

Finland's Parliament, meanwhile, said which made the site hard to use, with many pages not loading and some functions not available.

A pro-Russian hacker group known as NoName057 (16) claimed responsibility, saying the attack was retaliation for Finland joining NATO. The claim could not be immediately verified.

The hacker group, which has reportedly acted on Moscow’s orders, has taken part in a slew of cyberattacks on the U.S. and its allies in the past. Finnish public broadcaster YLE said the same group hit the Parliament's site last year.

___

Associated Press writers David Keyton in Stockholm, Sweden, and Jari Tanner in Helsinki contributed.

___

Follow AP's coverage of the war in Ukraine at

The ɫֱ Press. All rights reserved.