An Olympic athlete from Great Britain has withdrawn from the Games just days before the opening ceremony due to a video showing alleged mistreatment of a horse.

Charlotte Dujardin, an equestrian rider, is accused of "engaging in conduct contrary to the principles of horse welfare." 

Dujardin said a video "from four years ago … which shows me making an error of judgment during a coaching session," recently emerged, leading to an investigation.

CLICK HERE FOR MORE SPORTS COVERAGE ON foxnews.1eye.us

Charlotte Dujardin

Charlotte Dujardin poses with her horse Pete (Imhotep) during a Team GB Paris 2024 Olympic Games equestrian team announcement at Oakelbrook Mill July 2, 2024, in Newent, England. (Dan Istitene/Getty Images)

"Understandably, the International Federation for Equestrian Sports (FEI) is investigating, and I have made the decision to withdraw from all competition — including the Paris Olympics — while this process takes place," the three-time gold medalist said in a statement.

"What happened was completely out of character and does not reflect how I train horses or coach my pupils, however there is no excuse. I am deeply ashamed and should have set a better example in that moment. I am sincerely sorry for my actions and devastated that I have let everyone down, including Team GB, fans and sponsors. I will cooperate fully with the FEI, British Equestrian Federation and British Dressage during their investigations and will not be commenting further until the process is complete."

Dujardin will also be under a six-month suspension by the FEI.

Charlotte Dujardin in competition

Charlotte Dujardin with Imhotep in a competition during the Team Grand Prix at the FEI European Championships Dressage 2023 Sept. 7, 2023, in Horstel, Germany.  (Jenny Musall/DeFodi Images via Getty Images)

ANDY MURRAY ANNOUNCES PLANS TO RETIRE AFTER 2024 PARIS OLYMPICS

It is unclear what the nature of the video is that prompted the investigation.

Dujardin earned gold twice in 2012, winning both the team and individual dressage events. She won gold in the individual event in 2016 in Rio and won silver in the team event. Dujardin earned a bronze in both events in 2021 in Tokyo.

She and cyclist Dame Laura Kenny each share the record for most medals won at the Olympics by a female athlete from Great Britain with six each.

Charlotte Dujardin celebrating

Charlotte Dujardin from Great Britain waves.  (Rolf Vennenbernd/picture alliance via Getty Images)

CLICK HERE TO GET THE FOX NEWS APP

Dujardin rode the horse Valegro from 2011 until the horse's retirement in 2016.

Follow Fox News Digital’s sports coverage on X, and subscribe to the Fox News Sports Huddle newsletter.