Factual error: When Angel Eyes arrives at the Confederate Army Hospital, the Confederate flag that is flying is not the correct flag; it is the flag that people in the 20th century and later think of as the Confederate flag. The only rectangular flag with the blue St Andrew's cross on red was the Confederate navy flag and the battle flag of the Army of Tennessee, which was the standardized battle flag for the Western Armies (but not that far west) after January 1864, so didn't exist in the New Mexico campaign, nor at the time the story takes place.
Character mistake: At the confederate prison camp after they are captured a soldier comes up to the sergeant (Van Cleef) and informs him that the "Captain" wants to see him right away. In the next shot with Van Cleef where he is talking to the commanding officer you will see that he is not a captain but a major.
Continuity mistake: When Tuco pulls the corporal from train they fall down a steep grade. When train runs over the corporal, they're on flat ground. The corporal would be too heavy for Tuco to carry far enough for the ground to flatten out. Watch the ground when the train approaches before the jump.
Factual error: While cleaning his pistol Eastwood is using a plastic bore brush, not available in that era. (00:00:45 - 00:50:00)
Factual error: The movie depicts General Sibley's New Mexico campaign. This occurred in the first half of 1862, with the last battle occurring on June 1, prior to a Confederate retreat to Texas. General Sibley is seen, and he lost his battlefield command altogether in 1863. However, Angel Eyes makes reference to Andersonville prison, which did not open until 1864. The question is also begged as to how Art Scanlon, who died in February of 1862, had completely rotted away by May in dry soil.
Other mistake: About 20 minutes into the film, Tuco is arrested by the sheriff who rolls out a Wanted poster which has Tuco's picture. However, as can be seen (but only visible for a second or two), the name on the Wanted poster says Guy Calloway, who was a character in Leone's previous film For A Few Dollars More, who had a bounty on him (and a poster) and was killed by Col. Mortimer early in that film. Leone was notorious for trying to reuse props to save money (the Al Mulock story being the most infamous example), and possibly just reused the old poster with Wallach's picture on it, figuring nobody would notice.
Factual error: Regarding the train scenes when Tuco is taken then escapes from Mario Brega, there were no trains / railways in New Mexico in any of the years of the US Civil War, let alone 1862 when Selby's short-lived and daft campaign was limited to. I believe the RRs were starting to move into Texas then, but not NM until the 1870s. Also, the whole geography of the film is wrong if the gold was intercepted but 'escaped' with the three people in the wagon near Glorietta Pass in early 1862. The sequence of events means all involved had to go up and down the Rio Bravo constantly - eg. the 'jornado del muerto' is hundreds of miles from Glorietta. This is too complicated to summarise here, but check the actual battles and timelines.
Other mistake: Director Sergio Leone uses one of his trademark filming techniques throughout this film, where anything outside the camera frame doesn't exist. Several times the characters react to situations and other characters when they come into frame that they logically would've seen much sooner. For example, at one point Blondie and Tuco are walking and stumble across an army camp. Even though in reality they would have been walking toward it for a long time and would have been aware of it, they react with surprise the moment it appears on screen.
Factual error: Extended version. After finding a dying Bill Carson, Tuco arrives at an outpost looking for a hospital. It's night, or at least dark outside - he is told the hospital is 18 miles away. In the next scene he arrives at the hospital at nearly high noon. A horse canters and gallops (full speed) between 4-30 mph. Basically the hospital was an hour away.