Sampling challenges in deep-sea ecosystems lead to a lack of knowledge about the distribution of microbes in different submarine canyons. To study microbial diversity and community turnover under different ecological processes, we performed 16S/18S rRNA gene amplicon sequencing for sediment samples from a submarine canyon in the South China Sea. Bacteria, archaea, and eukaryotes made up 57.94% (62 phyla), 41.04% (12 phyla), and 1.02% (4 phyla) of the sequences, respectively. Thaumarchaeota, Planctomycetota, Proteobacteria, Nanoarchaeota, and Patescibacteria are the five most abundant phyla. Heterogeneous community composition was mainly observed in vertical profiles rather than horizontal geographic locations, and microbial diversity in the surface layer was much lower than that in deep layers. According to the null model tests, homogeneous selection dominated community assembly within each sediment layer, whereas heterogeneous selection and dispersal limitation dominated community assembly between distant layers. Different sedimentation processes of sediments, i.e., rapid deposition caused by turbidity currents or slow sedimentation, seem to be primarily responsible for these vertical variations. Finally, functional annotation through shotgun-metagenomic sequencing found that glycosyl transferases and glycoside hydrolases are the most abundant carbohydrate-active enzyme categories. The most likely expressed sulfur cycling pathways include assimilatory sulfate reduction, the link between inorganic and organic sulfur transformation, and organic sulfur transformation, while the potentially activated methane cycling pathways include aceticlastic methanogenesis and aerobic and anaerobic oxidation of methane. Overall, our study revealed high levels of microbial diversity and putative functions in canyon sediments and the important influence of sedimentary geology on microbial community turnover between vertical sediment layers. IMPORTANCE Deep-sea microbes have received growing attention due to their contribution to biogeochemical cycles and climate change. However, related research lags due to the difficulty of collecting samples. Based on our previous study, which revealed the formation of sediments under the dual action of turbidity currents and seafloor obstacles in a submarine canyon in the South China Sea, this interdisciplinary research provides new insights into how sedimentary geology influences microbial community assembly in sediments. We proposed some uncommon or new findings, including the following: (i) microbial diversity was much lower on the surface than in deeper layers (ii) archaea and bacteria dominated the surface and deep layers, respectively; (iii) sedimentary geology played key roles in vertical community turnover; and (iv) the microbes have great potential to catalyze sulfur, carbon, and methane cycling. This study may lead to extensive discussion of the assembly and function of deep-sea microbial communities in the context of geology.