It is the first time such a ruling has been made, the Sunday Star-Times reported.
The Auckland brothers, aged nine and 13, went to the High Court to appeal a March 20 Family Court ruling that laid out plans for gradually increasing the time the boys spent with their father.
The family had been in and out of the Family Court for the past six years.
On March 20 Judge Laurence Ryan said he was confident risks to the boys could be managed and he ruled contact was in the children's best interest.
In the High Court at Auckland Justice Judith Potter granted the boys' appeal and ordered their father to have only internet or written contact with his sons.
The Care of Children Act, introduced in 2004, grants children the right to appeal Family Court decisions.
A family law expert said the decisions were significant because they recognised children's rights to express their needs.
Last year the Family Court allowed a teenager to divorce her mother. But the High Court overturned that decision, reinstating the mother's guardianship of her daughter.