Background: Radiotherapy might augment systemic antitumoral responses to immunotherapy. In the PEMBRO-RT (phase 2) and MDACC (phase 1/2) trials, patients with metastatic non-small-cell lung cancer were randomly allocated immunotherapy (pembrolizumab) with or without radiotherapy. When the trials were analysed individually, a potential benefit was noted in the combination treatment arm. However, owing to the small sample size of each trial, differences in response rates and outcomes were not statistically significant but remained clinically notable. We therefore did a pooled analysis to infer whether radiotherapy improves responses to immunotherapy in patients with metastatic non-small-cell lung cancer. Methods: Inclusion criteria for the PEMBRO-RT and MDACC trials were patients (aged ≥18 years) with metastatic non-small-cell lung cancer and at least one unirradiated lesion to monitor for out-of-field response. In the PEMBRO-RT trial, patients had previously received chemotherapy, whereas in the MDACC trial, patients could be either previously treated or newly diagnosed. Patients in both trials were immunotherapy-naive. In the PEMBRO-RT trial, patients were randomly assigned (1:1) and stratified by smoking status (<10 vs ≥10 pack-years). In the MDACC trial, patients were entered into one of two cohorts based on radiotherapy schedule feasibility and randomly assigned (1:1). Because of the nature of the intervention in the combination treatment arm, blinding to radiotherapy was not feasible in either trial. Pembrolizumab was administered intravenously (200 mg every 3 weeks) with or without radiotherapy in both trials. In the PEMBRO-RT trial, the first dose of pembrolizumab was given sequentially less than 1 week after the last dose of radiotherapy (24 Gy in three fractions), whereas in the MDACC trial, pembrolizumab was given concurrently with the first dose of radiotherapy (50 Gy in four fractions or 45 Gy in 15 fractions). Only unirradiated lesions were measured for response. The endpoints for this pooled analysis were best out-of-field (abscopal) response rate (ARR), best abscopal disease control rate (ACR), ARR at 12 weeks, ACR at 12 weeks, progression-free survival, and overall survival. The intention-to-treat populations from both trials were included in analyses. The PEMBRO-RT trial (NCT02492568) and the MDACC trial (NCT02444741) are registered with ClinicalTrials.gov. Findings: Overall, 148 patients were included in the pooled analysis, 76 of whom had been assigned pembrolizumab and 72 who had been assigned pembrolizumab plus radiotherapy. Median follow-up for all patients was 33 months (IQR 32·4–33·6). 124 (84%) of 148 patients had non-squamous histological features and 111 (75%) had previously received chemotherapy. Baseline variables did not differ between treatment groups, including PD-L1 status and metastatic disease volume. The most frequently irradiated sites were lung metastases (28 of 72 [39%]), intrathoracic lymph nodes (15 of 72 [21%]), and lung primary disease (12 of 72 [17%]). Best ARR was 19·7% (15 of 76) with pembrolizumab versus 41·7% (30 of 72) with pembrolizumab plus radiotherapy (odds ratio [OR] 2·96, 95% CI 1·42–6·20; p=0·0039), and best ACR was 43·4% (33 of 76) with pembrolizumab versus 65·3% (47 of 72) with pembrolizumab plus radiotherapy (2·51, 1·28–4·91; p=0·0071). Median progression-free survival was 4·4 months (IQR 2·9–5·9) with pembrolizumab alone versus 9·0 months (6·8–11·2) with pembrolizumab plus radiotherapy (hazard ratio [HR] 0·67, 95% CI 0·45–0·99; p=0·045), and median overall survival was 8·7 months (6·4–11·0) with pembrolizumab versus 19·2 months (14·6–23·8) with pembrolizumab plus radiotherapy (0·67, 0·54–0·84; p=0·0004). No new safety concerns were noted in the pooled analysis. Interpretation: Adding radiotherapy to pembrolizumab immunotherapy significantly increased responses and outcomes in patients with metastatic non-small-cell lung cancer. These results warrant validation in a randomised phase 3 trial. Funding: Merck Sharp & Dohme.