Background Pakistan faces huge challenges in eradicating polio due to widespread poliovirus transmission and security challenges. Innovative interventions are urgently needed to strengthen community buy-in, to increase the coverage of oral polio vaccine (OPV) and other routine immunisations, and to enhance immunity through the introduction of inactivated polio vaccine (IPV) in combination with OPV. We aimed to evaluate the acceptability and effect on immunisation coverage of an integrated strategy for community engagement and maternal and child health immunisation campaigns in insecure and conflict-affected polio-endemic districts of Pakistan. Methods We did a community-based three-arm cluster randomised trial in healthy children aged 1 month to 5 years that resided within the study sites in three districts of Pakistan at high risk of polio. Clusters were randomly assigned by a computer algorithm using restricted randomisation in blocks of 20 by an external statistician (1:1:1) to receive routine polio programme activities (control, arm A), additional interventions with community outreach and mobilisation using an enhanced communication package and provision of short-term preventive maternal and child health services and routine immunisation (health camps), including OPV (arm B), or all interventions of arm B with additional provision of IPV delivered at the maternal and child health camps (arm C). An independent team conducted surveys at baseline, endline, and after each round of supplementary immunisation activity for acceptability and effect. The primary outcome measures for the study were coverage of OPV, IPV, and routine extended programme on immunisation vaccines and changes in the proportion of unvaccinated and fully vaccinated children. This trial is registered with ClinicalTrials.gov, number NCT01908114. Findings Between June 4, 2013, and May 31, 2014, 387 clusters were randomised (131 to arm A, 127 to arm B, and 129 to arm C). At baseline, 28 760 children younger than 5 years were recorded in arm A, 30 098 in arm B, and 29 126 in arm C. 359 clusters remained in the trial until the end (116 in arm A, 120 in arm B, and 123 in arm C; with 23 334 children younger than 5 years in arm A, 26 110 in arm B, and 25 745 in arm C). The estimated OPV coverage was 75% in arm A compared with 82% in arm B (difference vs arm A 6·6%; 95% CI 4·8–8·3) and 84% in arm C (8·5%, 6·8–10·1; overall p<0·0001). The mean proportion of routine vaccine doses received by children younger than 24 months of age was 43% in arm A, 52% in arm B (9%, 7–11) and 54% in arm C (11%, 9–13; overall p<0·0001). No serious adverse events requiring hospitalisation were reported after immunisation. Interpretation Despite the challenges associated with the polio end-game in high-risk, conflict-affected areas of Pakistan, a strategy of community mobilisation and targeted community-based health and immunisation camps during polio immunisation campaigns was successful in increasing vaccine coverage, including polio vaccine coverage. Funding Bill & Melinda Gates Foundation.