This is a historic moment for Sweden, which has spent the past year fighting hard to get accepted into Nato.
The Nordic country previously embraced wartime neutrality for more than 200 years, but applied for membership last May as part of efforts to improve security and stability in northern Europe, following Russia’s invasion of Ukraine.
However, until late on Monday night, Turkey had been blocking Sweden’s application.
Turkey argued Sweden was giving refuge to Kurdish militants, and needed to do more to crack down on rebel groups like the Kurdistan Workers’ Party (PKK), which it considers a terrorist organisation. The EU and US have also designated the PKK as a terrorist group.
Like any of Nato’s 31 member countries, Turkey has the power to block new nations from joining the group.
The outcome of crunch talks with President Recep Tayyip Erdogan is being seen as a major win for Sweden’s right-wing Prime Minister Ulf Kristersson.
While Sweden’s initial application to join Nato was made by Mr Kristersson’s Social Democrat predecessor, Magdalena Andersson, he has made securing membership a key foreign policy priority since taking over as Swedish leader in October.
Sweden introduced tougher anti-terrorism laws in June, making it illegal to give financial or logistical help to terrorist groups.
He told Sweden’s public TV network SVT that he and his team had “worked very hard” to address Turkey’s concerns about terrorism, and that an agreement had been reached after being allowed to showcase their efforts.
Sweden has resumed armed exports to Turkey.
“We have taken seriously their very legitimate demand that every country that enters the alliance should contribute to additional security,” the prime minister told SVT.
After being photographed beaming in Vilnius on Monday, Mr Kristersson admitted on Swedish public radio that he had enjoyed a quick celebratory beer “with the whole gang” in a conference room after the talks.