The ruling came a day after the victim, Mukhtar Mai, in a dramatic appearance at the Supreme Court appealed a lower court decision to acquit five of the men who allegedly raped her on orders of a council of village elders. The eight members of the council, an influential force in rural Pakistan, were acquitted three years ago.
Outside the courtroom, dozens of women hugged and congratulated a relaxed and smiling Mai, who was dressed in the traditional Shalwar kameez (trousers and a shirt) with a blue and green shawl covering her head.
"I am happy and I hope those who humiliated me will be punished," the 33-year old told reporters after the court ordered the retrial of all 13 men. "I was expecting justice from the Supreme Court and the Supreme Court has done justice."
A trial date has yet to be set, said Malik Salim, a lawyer for one of the men.
Mai was raped in 2002 allegedly as punishment for her 13-year-old brother's illicit affair with a woman from a higher-caste family. Mai and her family deny any affair ever took place, and say the brother was in fact assaulted by members of the other family.
By confronting her attackers, Mai has defied tradition in a country where rape victims often suffer in silence for fear that they will be shunned by their families if they come forward.
In the years since the assault, Mai has become a prominent activist for women's rights and has helped set up a school in her impoverished farming village, mainly with donations from her supporters.
But her attempts to take the plight of women in rural Pakistan to a wider audience were muzzled by the government.
Mai had been invited by a U.S-based human rights group to talk about her experiences, but was stopped from leaving Pakistan and her passport was confiscated.
President Gen. Pervez Musharraf, while on a trip to New Zealand, said he ordered the travel ban to prevent Mai bad mouthing Pakistan.
The move was strongly criticized by the United States and human rights groups and on Monday Mai received her passport back. It wasn't clear Tuesday whether Mai intended to continue with her trip to the U.S.
A trial court in 2002 sentenced six men to death and acquitted eight others in Mai's rape. In March of this year, the High Court in Punjab province, where Mai's village of Meerwala is located, acquitted five of the men and reduced the death sentence of the sixth to life in prison.