OBJECTIVE: To measure the 90 day risk of arterial thromboembolism and venous thromboembolism among patients diagnosed with covid-19 in the ambulatory (ie, outpatient, emergency department, or institutional) setting during periods before and during covid-19 vaccine availability and compare results to patients with ambulatory diagnosed influenza. DESIGN: Retrospective cohort study. SETTING: Four integrated health systems and two national health insurers in the US Food and Drug Administration's Sentinel System. PARTICIPANTS: Patients with ambulatory diagnosed covid-19 when vaccines were unavailable in the US (period 1, 1 April-30 November 2020; n=272 065) and when vaccines were available in the US (period 2, 1 December 2020-31 May 2021; n=342 103), and patients with ambulatory diagnosed influenza (1 October 2018-30 April 2019; n=118 618). MAIN OUTCOME MEASURES: Arterial thromboembolism (hospital diagnosis of acute myocardial infarction or ischemic stroke) and venous thromboembolism (hospital diagnosis of acute deep venous thrombosis or pulmonary embolism) within 90 days after ambulatory covid-19 or influenza diagnosis. We developed propensity scores to account for differences between the cohorts and used weighted Cox regression to estimate adjusted hazard ratios of outcomes with 95% confidence intervals for covid-19 during periods 1 and 2 versus influenza. RESULTS: 90 day absolute risk of arterial thromboembolism with covid-19 was 1.01% (95% confidence interval 0.97% to 1.05%) during period 1, 1.06% (1.03% to 1.10%) during period 2, and with influenza was 0.45% (0.41% to 0.49%). The risk of arterial thromboembolism was higher for patients with covid-19 during period 1 (adjusted hazard ratio 1.53 (95% confidence interval 1.38 to 1.69)) and period 2 (1.69 (1.53 to 1.86)) than for patients with influenza. 90 day absolute risk of venous thromboembolism with covid-19 was 0.73% (0.70% to 0.77%) during period 1, 0.88% (0.84 to 0.91%) during period 2, and with influenza was 0.18% (0.16% to 0.21%). Risk of venous thromboembolism was higher with covid-19 during period 1 (adjusted hazard ratio 2.86 (2.46 to 3.32)) and period 2 (3.56 (3.08 to 4.12)) than with influenza. CONCLUSIONS: Patients diagnosed with covid-19 in the ambulatory setting had a higher 90 day risk of admission to hospital with arterial thromboembolism and venous thromboembolism both before and after covid-19 vaccine availability compared with patients with influenza.