Russian President Vladimir Putin signed a mutual defence agreement on Wednesday with North Korea's Kim Jong Un, who offered his "full support" on Ukraine.
The pledge of military cooperation was part of a strategic treaty signed during a summit in Pyongyang, where Putin was making his first visit in 24 years.
"It is really a breakthrough document," Putin told a news conference in the North Korean capital, adding that it provided, "among other things, for mutual assistance in case of aggression against one of the parties to this treaty", Russian news agencies said.
The two countries have been allies since North Korea's founding after World War II and have drawn even closer since Russia's invasion of Ukraine in 2022 isolated Putin on the global stage.
The United States and its allies have accused North Korea of providing ammunition and missiles to Russia for its war in Ukraine, and the treaty was certain to fuel concerns of more deliveries.
Putin also said Russia "does not rule out military-technical cooperation with the DPRK in connection with the treaty that was signed today", referring to North Korea by its official name.
Kim called Putin the "dearest friend of the Korean people" and said his country "expresses full support and solidarity to the Russian government" over the war in Ukraine, which has triggered rafts of UN sanctions on Moscow.
Putin, in turn, thanked his host Kim -- whose country has been under a UN sanctions regime since 2006 over his banned weapons programmes -- saying Moscow appreciated the "consistent and unwavering" support.
Putin said the two heavily sanctioned countries would not tolerate Western "blackmail" and called for a review of UN sanctions on North Korea.
"The indefinite restrictive regime inspired by the US and its allies at the UN Security Council towards the DPRK should be reviewed," Putin said.
Putin also said Moscow and Pyongyang were fighting "US hegemony" together and commended the North for its "balanced position" on Ukraine.
"Today, we are fighting together against the hegemonism and neo-colonial practices of the United States and its satellites," he said.
Red carpet
Putin arrived in Pyongyang before dawn on Wednesday and was greeted by Kim on a red carpet at the airport, where the pair embraced and smiled.
They then attended a welcoming ceremony in Kim Il Sung Square, featuring a military band and mass synchronised dancing, after which Putin invited his host to visit Moscow.
The summit, which included a lengthy one-on-one chat between the leaders, was their second meeting in a year.
Kim took his bulletproof train to Russia's Far East in September for a summit with Putin at a spaceport.
Kim said the two countries' ties had now risen "to a new high of alliance".
"It is greatly satisfying to conclude a great treaty that befits a changed international situation and the strategic nature of new DPRK-Russia relations," he said.
Kim also said the new treaty "fully contributes to maintaining peace and stability in the region".
'Arsenal for autocracy'
Vladimir Tikhonov, professor of Korean Studies at the University of Oslo, told AFP that Russia will now "largely sabotage the sanctions regime around North Korea, in deed if not in word".
The new mutual support clause is "a reminder to Americans that Russia may complicate their lives if they support Ukraine too enthusiastically", he said, pointing to the around 28,000 US troops based in South Korea, a key regional security ally of Washington.
The deal between Moscow and Pyongyang "may make US military planning on the Korean Peninsula a much more complex affair", Tikhonov said.
The two Koreas have remained technically at war since their 1950-53 conflict and the border dividing them is one of the most heavily fortified in the world.
This week's visit was a way for Putin to thank the North "for acting as an 'arsenal for autocracy' in support of his illegal invasion of Ukraine", said Leif-Eric Easley, a professor at Ewha University in Seoul.
It was also part of Russia's drive to secure "strategic space" in Northeast Asia to counter US influence in the region, Seoul-based Institute for National Security Strategy's senior research fellow Kim Sung-bae told AFP.
"This intention is further evidenced by Putin's visit to Vietnam," he said, with the Russian leader set to fly to Hanoi after his trip to the North.