Background: Mucin 1 (MUC1) plays a major role in the occurrence and development of tumor by regulating the process of tumor cell proliferation, epithelial-mesenchymal transformation and epigenetics. However, the relationship between MUC1 expression and tumor prognosis and its role in tumor immunity is still worth exploring. Methods: MUC1 expression was analyzed via GTEx database and TCGA database. We used the Kaplan-Meier survival estimation method to evaluate the influence of MUC1 on tumor prognosis through the survival information from TGCA database. The correlations between MUC1 and immune cell infiltration, tumor microenvironment were investigated through TIMER algorithm and ESTIMATE. In addition, we used Spearman correlation test to examine the correlation between MUC1 and TMB, MSI. Spearman correlation test was also designed to predict the correlation between MUC1 and immune checkpoint genes, four methyltransferases. Further, Gene Set Enrichment Analysis was used to explore the potential mechanism of MUC1 in Adrenocortical carcinoma (ACC) and Liver hepatocellular carcinoma (LIHC). Results: Our study reported that MUC1 is highly expressed in most tumors, differing between cancer types. In most cancers, high expression of MUC1 means poor prognosis indicators, such as overall survival (OS), disease free survival (DSS), disease free survival (DFS) and progression free survival (PFS). MUC1 was positively correlated with infiltrating levels of B cells, CD4+ T cells and CD8+ T cells, dendritic cells, macrophages, neutrophils in LIHC, Prostate adenocarcinoma (PRAD) and Thyroid carcinoma (THCA). Besides, we reported that the expression of MUC1 correlated significantly with immune checkpoint gene, TMB and MSI and in most tumors. However, we found that MUC1 is negatively correlated with most immunotherapy-related indicators in BRCA and LUAD. The relationship between MUC1 and tumor neoantigens and DNA methylase is different in different tumors.In ACC and LIHC, MUC1 can promote the metabolism of many substances. MUC1 can inhibit amyotrophic lateral sclerosis, DNA replication, base excision repair, proteasome in ACC. Similarly, MUC1 inhibits axon guidance, the interaction of cytokine and cytokine receptor, focal adhesion, and endocytosis in LIHC. Conclusions: Our research demonstrates that MUC1 is correlated with prognosis and tumor-infiltrating immune cells, including those of B cells, CD8+ T cells, CD4+ T cells, dendritic cells, macrophages, neutrophils in different tumors. In addition, MUC1 is related to immune checkpoint gene, neoantigen, and some prognostic indicators of immunotherapy such as TMB and MSI, suggesting that MUC1 can also be invoked as a target and prognostic biomarker of immunotherapy. By analyzing the relationship between the expression of MUC1 and methyltransferase, we found that MUC1 regulates DNA methylation. Finally, we used GSEA to study the function of MUC1 in ACC and LIHC. Briefly, our study highlights the significance of MUC1 in the study of tumor immunity from the perspective of pan-cancer.