Algeria received around 80 total MiG-23s of various variants (including the ground-attack MiG-23BN and the fighter-interceptor MiG-23MF) from the Soviet Union starting in 1979.
All third-generation MiG-23s were phased out of service by the early 2000s, with the last aircraft retired around 2004-2008 as the air force modernized with more advanced fourth-generation fighters like the Su-30MKA and MiG-29.
The MiG-23MS was primarily used as an interceptor aircraft in the air defense role.