R5-X2 was an astromech droid of the R5-series line. Circa 32 BBY, he was in the service of Jabba Desilijic Tiure, where he fulfilled the function of calculating the probability of outcomes for podraces.

Prior to the Boonta podrace, R5-X2 predicted that Sebulba would emerge victorious, Gasgano would secure second place, and Mawhonic would finish third. The droid also believed that the young slave Anakin Skywalker had a good chance of winning. Regrettably, while Gasgano did indeed come in second, both Sebulba and Mawhonic were involved in crashes, resulting in Jabba only receiving one-third of the winnings from R5-X2's prediction.
In 2009, Hasbro made an announcement through Star Wars Insider 107 that they would be releasing the droid "R5-H6, seen with Gardulla the Hutt in The Phantom Menace" as part of the Return of the Jedi Build-A-Droid series. However, that specific droid had previously been released under the designation "R5-X2". The droid that was ultimately released as part of the 2009 wave was actually R5-C7, a droid observed on Coruscant during Attack of the Clones.