Ben Stokes has been found not guilty of affray.
Stokes, who was arrested following an incident in Bristol in the early hours of September 25, had been on trial at Bristol Crown Court since August 6.
His co-defendant, Ryan Ali, was also found not guilty after more than two-and-a-half hours of deliberation by a jury of six men and six women.
At the moment that the verdict was delivered, Stokes' wife Clare broke down in tears, then Neil Fairbrother, his agent, did likewise. Stokes himself, who had been calm in the dock, allowed himself to shut his eyes for a moment but didn't break into a smile. He then offered his hand to Ali, who shook it.
Speaking outside the courtroom after the verdict, Stokes' solicitor, Paul Lunt, said that the jury's verdict "fairly reflects the truth of what happened that night".
"Today's verdict represents the end of an 11-month ordeal for Ben," said Lunt in a statement, "during which time he's had to maintain his silence at times when many on social media, and in certain parts of the press, have pre-determined his guilt long before the trial was done.
"During the past week, the jury have been able to see and hear all of the evidence and not merely what the media have chosen to report. The evidence available to the jury included the full range of CCTV footage that shows exactly what happened in September."
During the trial, Stokes was alleged to have lied to the jury, mimicked and bullied two men on account of their homosexuality and acted like a football hooligan. He did not deny punching two men (Ali and Ryan Hale, who was acquitted earlier in proceedings due to a lack of evidence), but insisted he did so as he feared for his safety and the safety of others.
Ali was alleged to have used an upturned bottle in the early moments of the fracas, while CCTV footage showed Hale running towards the incident with an iron bar ripped from a traffic sign.
"On 25 September, Ben had been out with two mates, celebrating a win," said Lunt. "Contrary to some reports, there was no curfew in place, he was minding his own business when he came across two men being subjected to what Ben identified as serious homophobic abuse.
"It was only when others came under threat that Ben became physically engaged with the men in question. The steps that he took were solely aimed at ensuring the safety of himself and the others present."
Speaking to ITV news, the two gay men in question - who did not give evidence during the court case - said that the case should not have come to trial.
"Someone came across the road and tried hitting me with a bottle," said Kai Barry. "I thought he was just a normal lad, sticking up for somebody who was weaker than he was, which was quite nice. When I realised who he was, I thought, fair play, because he's obviously put his career at risk for someone that he never knew. I'd say thanks for being there, and sorry for all the drama I've landed you in."
Ali, who left the court a few minutes after the verdict had been passed, told reporters he was "relieved it's all over" but had no further comment to make.
The end of the court proceedings has enabled Stokes to be cleared by the ECB to rejoin England's squad for the third Test against India starting in Nottingham on Saturday. The ECB are expected to convene a Cricket Discipline Commission, which will consider whether Stokes or Alex Hales, who was also present during the incident, should face any sanction. However, ESPNcricinfo understands that this may not take place until the end of the English cricket season.
It has not gone unnoticed by the ECB that both men were out late at night - the incident occurred after 2.30am - with two games left to play in the series and that Stokes was alleged to have been "really very drunk" by the prosecution.
Any possible sanction by the CDC will take into account that Stokes has already missed the Ashes tour as a result of the episode - Hales also missed two ODIs at the end of the 2017 English domestic season - and Stokes' lawyer drew attention to the amount of cricket-related punishment that he had already received for his actions.
"In addition to the extreme stress placed on Ben and his family by the trial, his intervention that night has already cost Ben the England vice-captaincy, his place on an Ashes tour, and his place in a number of other England matches," said Lunt.
"The past 11 months have served to highlight to Ben just how highly he values his position as an England representative, both in terms of the privilege that role entails and the responsibilities that accompany it. Now that the trial is over, Ben is keen to getting back to cricket being his sole focus."
During the trial the jury was shown body-worn video footage from the arresting police officer that appeared to show Hales denying he had been present at the incident, while both the prosecution and defence barristers alleged video footage showed him kicking Ali in the head. Stokes' barrister, Gordon Cole QC, suggested that kick could have resulted in Ali's broken eye-socket.
Reacting to the verdict, an Avon and Somerset Police spokesman said: "We carried out a thorough independent investigation into the events of 25 September before passing a comprehensive file of evidence to the Crown Prosecution Service which subsequently made the decision to charge.
"Having reviewed the evidence, the jury has concluded the actions of the defendants did not amount to affray and we respect this decision."
The Crown Prosecution Service, which had attempted to have the charges against Stokes changed prior to the trial, also issued a statement in the wake of the verdict.
"The CPS keeps cases under continual review," it read. "We selected the charge of affray at the outset in accordance with the Code for Crown Prosecutors. Upon further review we considered that additional assault charges would also be appropriate. The Judge decided not to permit us to add these further charges. The original charge of affray adequately reflected the criminality of the case and we proceeded on that."
George Dobell is a senior correspondent at ESPNcricinfo