BACKGROUND: The safety, effectiveness, and cost-effectiveness of molnupiravir, an oral antiviral medication for SARS-CoV-2, has not been established in vaccinated patients in the community at increased risk of morbidity and mortality from COVID-19. We aimed to establish whether the addition of molnupiravir to usual care reduced hospital admissions and deaths associated with COVID-19 in this population. METHODS: PANORAMIC was a UK-based, national, multicentre, open-label, multigroup, prospective, platform adaptive randomised controlled trial. Eligible participants were aged 50 years or older-or aged 18 years or older with relevant comorbidities-and had been unwell with confirmed COVID-19 for 5 days or fewer in the community. Participants were randomly assigned (1:1) to receive 800 mg molnupiravir twice daily for 5 days plus usual care or usual care only. A secure, web-based system (Spinnaker) was used for randomisation, which was stratified by age (<50 years vs ≥50 years) and vaccination status (yes vs no). COVID-19 outcomes were tracked via a self-completed online daily diary for 28 days after randomisation. The primary outcome was all-cause hospitalisation or death within 28 days of randomisation, which was analysed using Bayesian models in all eligible participants who were randomly assigned. This trial is registered with ISRCTN, number 30448031. FINDINGS: Between Dec 8, 2021, and April 27, 2022, 26 411 participants were randomly assigned, 12 821 to molnupiravir plus usual care, 12 962 to usual care alone, and 628 to other treatment groups (which will be reported separately). 12 529 participants from the molnupiravir plus usual care group, and 12 525 from the usual care group were included in the primary analysis population. The mean age of the population was 56·6 years (SD 12·6), and 24 290 (94%) of 25 708 participants had had at least three doses of a SARS-CoV-2 vaccine. Hospitalisations or deaths were recorded in 105 (1%) of 12 529 participants in the molnupiravir plus usual care group versus 98 (1%) of 12 525 in the usual care group (adjusted odds ratio 1·06 [95% Bayesian credible interval 0·81-1·41]; probability of superiority 0·33). There was no evidence of treatment interaction between subgroups. Serious adverse events were recorded for 50 (0·4%) of 12 774 participants in the molnupiravir plus usual care group and for 45 (0·3%) of 12 934 in the usual care group. None of these events were judged to be related to molnupiravir. INTERPRETATION: Molnupiravir did not reduce the frequency of COVID-19-associated hospitalisations or death among high-risk vaccinated adults in the community. FUNDING: UK National Institute for Health and Care Research.