New Zealand Army soldiers used code words and messenger apps to help navigate "chaotic and dangerous" scenes to evacuate Kiwis in Afghanistan.
However, having to leave some New Zealand visa holders behind weighed heavily on the minds of the Defence Force, Commander Joint Forces New Zealand Rear Admiral Jim Gilmour said.
There were horrific scenes in the last days of evacuations as people clung to the bottom of planes as they took off from Kabul's main airport last month, fearful of being left behind and instead dropping to their deaths.
The Taliban took over the war-torn country last week and now the world remains on tenterhooks as to how it would be run, if women would be equal, or if it would resort back to its 1990s style.
Gilmour said the evacuation of Kiwis had been a huge multi-agency, international effort.
"Our thoughts are with those New Zealand visa holders still in Afghanistan who wanted to evacuate but have been unable to," he said.
While acknowledging those facing uncertainty in Afghanistan, he said he was proud of Defence Force personnel who "worked tirelessly to bring many others to safety here in New Zealand".
As part of the NZDF's Operation Kōkako, New Zealand Army soldiers were on the ground at Hamid Karzai International Airport in Kabul and used code words and instructions sent on messenger apps to help evacuees reach the soldiers, where they could be taken to safety within the airport perimeter.
The Royal New Zealand Air Force C-130 Hercules deployed on the mission completed three flights to Kabul, and had two more flights scheduled before being forced to pull out due to an imminent security threat that was realised just hours later with an attack claimed by Isis-K that left 170 civilians and 13 United States military dead, with many more injured.
Other members of the NZDF contingent were at a base in the United Arab Emirates, supporting evacuees prior to their onward travel to New Zealand.
Rear Admiral Gilmour said all those involved had worked through an "incredibly fluid and complex situation" to bring people to safety.
Gilmour praised their efforts in evacuating New Zealand nationals, their families and other visa holders from Kabul following the takeover of Afghanistan by the Taliban.
"There are real stories of bravery, initiative and professionalism among our personnel and equally of bravery and incredible resilience among evacuees."
Although NZDF deployed about 80 personnel on the operation, it was estimated that around 600 NZDF staff were involved in a range of activities from planning, logistics and co-ordination through to mobilisation in order to achieve the mission.
Hundreds of staff from other Government agencies and thousands from international partners were involved in the humanitarian effort.
"While acknowledging those facing uncertainty in Afghanistan, I am very proud of our personnel who worked tirelessly to bring many others to safety here in New Zealand."
The majority of NZDF personnel involved with the Afghanistan evacuations had returned to New Zealand and would now complete two weeks of managed isolation.
"There has been a phased return of NZDF personnel.
"One member of the NZDF medical team returned on a civilian flight with evacuees, in case their medical support had been required. Aircrew and maintenance personnel returned on the aircraft at the weekend.
"Other members of the Op Kōkako contingent have returned to New Zealand on civilian flights.
"A small number of logistics support staff are still in the United Arab Emirates, due to return to New Zealand approximately mid-September."