The aim of this study was to determine whether a temporary rise in sexual risk behaviour during war in Guinea–Bissau could explain the observed trends in HIV-1 and HIV-2 prevalence, and to explore the possible contribution of competitive elimination of HIV-2 by HIV-1. A simulation model of the heterosexual transmission of sexually transmitted infections was parameterized using demographic, behavioural and epidemiological data from rural Guinea–Bissau, and fitted to the observed HIV-1 and HIV-2 trends with and without a historic rise in risk behaviour. The observed trends could only be simulated by assuming a temporary rise in risk behaviour. Around 30% of the projected decline in HIV-2 prevalence from a peak of 8·7% to 4·3% in 2010 was due to competitive elimination by HIV-1. Importantly for public health, HIV-1 prevalence was predicted to continue increasing and to become the dominant HIV type by 2010. Data collection is required to validate this prediction.