The ending of Never Say Never Again settles three things: Largo dies, the warhead is disarmed and Bond walks away from MI6 in words, if not in fact.
Start with the kill. Bond fights Largo underwater at the Tears of Allah, the closing set piece, but Domino lands the final blow with a spear gun. That choice gives her the payoff, because her brother, the USAF pilot whose altered eye SPECTRE used to get past security, was killed in the scheme, and Largo is her lover turned captor. She has already been taken with Bond to Largo's base in North Africa, and once Bond frees her she wants revenge. The spear gun is where that arc ends. In my opinion, that makes the finale feel earned for the story rather than just for the star. Bond then disarms the second warhead, and the NATO threat is over.
The staging matters too. The Tears of Allah cavern was built at Elstree Studios, while the film's earlier sequences used real locations: Fort Carre in Antibes as Largo's fortress, Nassau in the Bahamas and Luton Hoo as the health spa. Kershner and cinematographer Douglas Slocombe therefore close the film in a controlled studio space after a picture that otherwise travels from England to the French Riviera and the Bahamas. In my opinion, the contrast helps: the last fight is cramped and personal after the globe-trotting.
Then comes the last beat. Back in the Bahamas, Bond says he will not return to MI6, and Domino doubts he means it. It could be argued that this exchange is the film's whole title in one scene, since Bond is the sort of agent who cannot stay retired. The film opens with an older Bond failing a training exercise and being sent to a clinic, so I read the ending as the answer: he got his edge back, and he will not stay away.
Compared with the official EON entries, which end on a villain's defeat and move on to the next mission, this film ends on a conversation about whether Bond can quit. That fits a one-off built around Sean Connery's return, a film made outside the 25-film series and not designed to lead into a sequel. Its $160 million worldwide gross on a $36 million budget shows audiences showed up for that return.