Abstract Objectives Multidisciplinary Team (MDT) aims to integrate cancer patient care plans and provide holistic care to improve clinical outcomes and quality of life. However, there is a lack of empirical evidence regarding the effect of MDT on polypharmacy in advanced cancer patients near the end of life, which warrants further investigation. Methods This retrospective cohort study utilizes the National Health Insurance Research Database (NHIRD), Taiwan Cancer Registry, and Cause of Death Statistics, provided by the Health and Welfare Data Science Center (HWDC), Ministry of Health and Welfare (MOHW). The study subjects were patients who were diagnosed with stage III or IV cancer, aged 65 or above, experienced recurrence or metastasis, and who died between 2014 and 2020. Propensity score matching (PSM) was employed, followed by analysis using the Generalized Estimating Equation (GEE) to examine the differences in the risk of polypharmacy in the last 30 days before death. In addition, to confirm the robustness of the results, we conducted two different sensitivity tests: the first way is to use different ages as sample selection criteria and only include people who died over 75 years old as study subjects; the second way is to use conditional logistic regression models as a multivariate statistical method. Results There were 35537 samples before matching, including 4942 who received MDT care and 30595 who did not. After 1:1 matching, 9884 patients were finally included in the analysis. The prevalence of polypharmacy significantly decreased during the study period from 59.90% to 58.80% (p = 0.03; trend test). When examined through different PIM criteria, patients who received care from MDT exhibited a lower risk of polypharmacy (OR = 0.91, 95% CI = 0.84-0.98). Conclusions Advanced cancer patients who received care from MDT during the end-of-life period had a significantly lower risk of polypharmacy. Key messages • The prevalence of polypharmacy significantly decreased during the study period from 2014 to 2020 among advanced cancer patients. • Advanced cancer patients who received care from MDT during the end-of-life period had a significantly lower risk of polypharmacy.