Camelot — the horse who came within a length of an historic Triple Crown — has been retired from racing.

The 4-year-old — whom trainer Aidan O’Brien called “the perfect racehorse” — will now stand at Coolmore Stud in Co Tipperary, Ireland.

Camelot, by Montjeu, was unbeaten as a 2-year-old and in 2012 became only the 3rd horse since Nijinsky in 1970 to achieve the 2,000 Guineas-Derby double.

But he was denied victory in the St Leger — the 3rd leg of the Triple Crown of English Classics — by the Mahmood al-Zarooni-trained Encke, by just ¾ of a length.

Encke was one of the Godolphin horses that tested positive for the anabolic steroid stanozolol in April this year.

Camelot was being aimed at next month’s Breeders’ Cup in California until he was found to be lame this morning (14 October).

He earned nearly £2million prize money during his career but had struggled this season — following a colic operation last October — winning only 1 of 3 starts.

But Aidan O’Brien said Camelot had been working very well prior to his retirement.

“Unfortunately we never saw the same brilliance on the racecourse as we had done before his colic operation,” he said on the Coolmore website.

“But he was showing signs of it at home in recent weeks, so it’s disappointing that he won’t get the opportunity to run again.”

He added: “From the very first time we saw him at the sales we just loved him.

“He was a beautiful horse with a terrific action. Speed, class and super-intelligent to go with it — he had it all.”