The aid workers -- a British woman, a Kenyan woman and two Afghans -- were bringing food to children and pregnant women in the remote and mountainous area when they were abducted.

The NATO-led coalition did not give any details on the rescue, but confirmed that all four were freed.

The two women were identified as Briton Helen Johnston and Moragwa Oirere, from Kenya.

"They are all now safe. Helen and Moragwa are receiving support from British Embassy staff in Kabul," the U.K Foreign Office said. "The two Afghan aid workers are returning to their families in Badakhshan."

Johnston's family welcomed the news.

"We are delighted and hugely relieved by the wonderful news that Helen and all her colleagues have been freed," they said in a statement. "We are deeply grateful to everyone involved in her rescue, to those who worked tirelessly on her behalf, and to family and friends for their love, prayers and support over the last 12 days."

Gen. John R. Allen, commander of the International Security Assistance Force, said it was a joint effort.

The U.K. Foreign Office said it is in touch with the families of the two women and the Afghan and Kenyan governments.

"We pay tribute to the bravery of the coalition forces which means that all four aid workers will soon be rejoining their families and loved ones. We have worked closely with the Afghan authorities throughout and we would like to thank them for their support."

U.K. forces were involved in the "carefully planned and coordinated operation," it added.