Development of the R-40 started in the 1960s, to become the main weapon of the MiG-25 Foxbat Interceptor and was introduced under the designation R-40T (semi-active radar homing) and R-40R (infrared homing).
After the Soviet pilot Viktor Belenko defected with his MiG-15 out of Japanese Airspace, the aircraft and the missiles were upgraded; these new missiles were called R-40RD and R-40TD. It was planned, that the MiG-25 should always fire two missiles on a target, with the aim of guaranteeing a kill, even if the enemy uses countermeasures. As the standard weaponry of the MiG-25 is always composed of a semi-active radar guided R-40 and an infrared homing R-40, one of each variant was fired on to a single target, so that if one misses the target, the other one can still hit because different countermeasures are needed to prevent the second one to hit. But the infrared homing missile has to be fired first, to prevent it locking on to the hot exhaust of the semi-active radar guided missile.
The R-40 is the largest air-to-air missile currently in existence and it is currently used by the MiG-31 Foxhound.