The quality of the total mesorectal excision specimen in rectal cancer surgery is assessed with a three-tier grade (mesorectal, intramesorectal and muscularis propria). This study aimed to analyse the prognostic impact of the total mesorectal excision grade on survival, and to identify risk factors for intramesorectal and muscularis propria resection in a population-based setting. All patients in the Swedish Colorectal Cancer Registry with rectal cancer stage I-III ≤ 10 cm from the anal verge, diagnosed 2015-2019, undergoing total mesorectal excision were analysed. Clinical, surgical and pathological data were retrieved and analysed for the following primary outcomes: local and distant recurrence and overall and relative survival; secondary outcomes were risk factors for total mesorectal excision grading (intramesorectal or muscularis propria resection). Of note, postoperative death < 30 days or recurrence within 90 days were exclusion criteria for survival and recurrence analysis. Recurrence-free patients with less than 3 years follow-up, and patients lacking data regarding recurrence, were also excluded from recurrence analyses. Overall, of 7979 patients treated during the study interval, 1499 patients were eligible for recurrence, 2441 patients for survival and 2476 patients for risk-factor analyses, of which 75% were graded mesorectal, 17% intramesorectal and 8% muscularis propria. Median follow-up for survival was 42 (1-77) months. The worst total mesorectal excision grading (muscularis propria resection) was an independent risk factor for local recurrence in multivariable analysis (HR 2.73, 95% c.i. 1.07 to 7.0, P = 0.036). Total mesorectal excision grade had no impact on distant recurrence or survival. Female sex, tumour level <5 cm, abdominoperineal resection, minimally invasive surgery (laparoscopic and robotic), high blood loss, long duration of surgery and intraoperative perforation were independent risk factors for worse total mesorectal excision grading (intramesorectal and/or muscularis propria resection) in multivariable analyses. Muscularis propria resection increases the risk of local recurrence but does not seem to affect distant recurrence or survival.