Background In the AVERROES study, apixaban, a novel factor Xa inhibitor, reduced the risk of stroke or systemic embolism in patients with atrial fibrillation who were at high risk of stroke but unsuitable for vitamin K antagonist therapy. We aimed to investigate whether the subgroup of patients with previous stroke or transient ischaemic attack (TIA) would show a greater benefit from apixaban compared with aspirin than would patients without previous cerebrovascular events. Methods In AVERROES, 5599 patients (mean age 70 years) with atrial fibrillation who were at increased risk of stroke and unsuitable for vitamin K antagonist therapy were randomly assigned to receive apixaban (5 mg twice daily) or aspirin (81-324 mg per day). The mean follow-up was 1.1 years. The primary efficacy outcome was stroke or systemic embolism; the primary safety outcome was major bleeding. Patients and investigators were masked to study treatment. In this prespecified subgroup analysis, we used Kaplan-Meier estimates of 1-year event risk and Cox proportional hazards regression models to compare the effects of apixaban in patients with and without previous stroke or TIA. AVERROES is registered at ClinicalTrials.gov, number NCT00496769. Findings In patients with previous stroke or TIA, ten events of stroke or systemic embolism occurred in the apixaban group (n=390, cumulative hazard 2.39% per year) compared with 33 in the aspirin group (n=374, 9.16% per year; hazard ratio [HR) (1.29, 95% CI 0.15-0.60). In those without previous stroke or TIA, 41 events occurred in the apixaban group (n=2417, 1"68% per year) compared with 80 in the aspirin group (n=2415, 3.06% per year; HR 0.51, 95% CI 0.35-0.74). The p value for interaction of the effects of aspirin and apixaban with previous cerebrovascular events was 0.17. Major bleeding was more frequent in patients with history of stroke or TIA than in patients without (HR 2.88, 95% CI 1.77-4.55) but risk of this event did not differ between treatment groups. Interpretation In patients with atrial fibrillation, apixaban is similarly effective whether or not patients have had a previous stroke or TIA. Given that those with previous stroke or TIA have a higher risk of stroke, the absolute benefits might be greater in these patients.