Recent studies have emphasized that there is a strong link between the gut microbiome and the brain that affects social behavior and personality in animals. However, the interface between personality and the gut microbiome in wild primates remains poorly understood. Here, we used high-throughput sequencing and ethological methods in primate behavioral ecology to investigate the relationship between gut microbiome and personality in Tibetan macaques (Macaca thibetana). The behavioral assessment results indicated three personality dimensions including socialization, shyness, and anxiety. There was significant variation in alpha diversity only for shyness, with a significantly lower alpha diversity indices (including Shannon, Chao1, and PD) for bold individuals than for shy individuals. Using regression models to control for possible confounding factors, we found that the relative abundance of three genera, Akkermansia, Dialister, and Asteroleplasma, was significantly and positively correlated with the sociability scores in the macaques. In addition, Oscillospiraceae exhibited a positive correlation with scores for Shy Dimension. Furthermore, we found that the predicted functional genes for propionate and pyruvate, porphyrin and chlorophyll metabolic pathways related to animal behavior, were significant enriched in shyness group. We propose that the gut microbiome may play an important role in the formation of personality of Tibetan macaques.