Summary Myasthenia gravis (MG) is known to be epidemiologically associated with abnormalities of the thymus, an organ that maintains central tolerance. However, due to the complexity of the thymus, specific characteristics related to the pathogenesis of MG remain elusive. In our study, we attempted to narrow down the features associated with MG using spatial transcriptome analysis of thymoma and thymic hyperplasia samples. We found that the majority of thymomas were constituted by the cortical region, whereas the medullary region was localized in comparatively restricted areas. Moreover, the medullary region contained polygenic enrichment, MG-specific germinal center structures, and a supporting immune microenvironment. Additionally, neuromuscular medullary thymic epithelial cells (nmTECs), previously identified as MG-specific autoantigen-producing cells, were situated at the cortico-medullary junction. The immune microenvironment in the medulla was characterized by a specific chemokine pattern and specific immune cells, such as CCR7 + migratory dendritic cells (migDCs) and effector regulatory T (Treg) cells. Furthermore, similar germinal center structures and immune microenvironments were observed in the medulla during thymic hyperplasia. This study indicates that the medulla and junction areas are related to the pathology of MG, suggesting that these areas should be the focus of future studies on MG pathogenesis and drug targeting.