BNP leader Nick Griffin fought off a bid to have him declared guilty of contempt of court today.
The Equality and Human Rights Commission accused him of failing to comply with a Central London County Court judgment ordering the removal of potentially racist clauses from his party's constitution.
Robin Allen QC, appearing for the watchdog, said the BNP was "playing with" the Commission and its officials instead of obeying the judgment.
But today Lord Justice Moore-Bick and Mr Justice Ramsey, sitting at the High Court in London, refused to to take action against Mr Griffin, BNP deputy Simon Darby and party officer Tanya Lumby.
The Commission was seeking fines against them for contempt, or possibly the sequestration of party assets.
The application stemmed from the county court's ruling that the BNP constitution breached discrimination laws because of a clause banning non-white members.
The constitution underwent revision, but last March Judge Paul Collins ruled at the county court that the new version was indirectly discriminatory against those of mixed-race, because it required party applicants to oppose "any form of integration or assimilation of ... the indigenous British".
Another section required new members to submit to a two-hour vetting visit at their home by BNP officials, which Judge Collins ruled could be seen as "intimidatory".
The county judge ordered both sections to be removed from the constitution.
The Commission took the BNP to the High Court accusing it of being in contempt by failing to comply with that order.
Today, as BNP supporters demonstrated outside the Royal Courts of Justice, Lord Justice Moore-Bick said he had reached "the clear conclusion" that the Commission's legal action could not succeed.
Later, the Commission's legal group director, John Wadham, said today's ruling "makes no difference to the substance of our action against the BNP", which had finally obeyed the county court judgment.
He said: "Mr Griffin failed to properly implement that judgment until we took these proceedings in the High Court.
"When the Commission began proceedings against the BNP in June last year the party's constitution was plainly illegal. We asked that they amend it at the time.
"Had they done so we could have avoided court proceedings.
"Eighteen months and seven court hearings later Mr Griffin has finally amended the constitution to bring it in line with what the Commission had originally requested."
Mr Wadham said the Commission would continue to monitor any changes to the BNP's constitution "to ensure membership is made genuinely accessible".
"If we consider that it is not we will decide what regulatory action may again be necessary."
Mr Griffin described today's decision as "fantastic", saying the Commission had pursued a politically-motivated campaign designed to bankrupt the party.
In his ruling, Lord Justice Moore-Bick said it was plain that the BNP constitution had been restructured in response to the county court order.
The restructuring involved removing conditions formerly attached to admission and reinstating them under "conditions of membership" as barriers to "active participation" in the party's affairs.
The judge said the phrase "conditions of membership" could reasonably be construed as having two possible meanings, and for that reason alone it would be wrong to find Mr Griffin guilty of contempt of the county court order.
In any event, the Commission had indicated that it would not press its application for sanctions against the BNP leadership in relation to breaches that had now been rectified.
The judge said the High Court had been concerned only with the scope of the order made by Judge Collins.
He warned: "It has not been concerned with the more general question whether any aspects of the BNP's current constitution infringe the prohibition on discrimination on the grounds of race now contained in the Equality Act 2010, which may have to be considered on another occasion."