The human gut harbours diverse and abundant microbes, forming a complex ecological system that interacts with host and environmental factors. In this article, we summarise recent advances in microbiome studies across both Western and non-Western populations, either in cross-sectional or longitudinal surveys, and over various age groups, revealing a considerable diversity and variability in the human gut microbiome. Of all the exogenous factors affecting gut microbiome, a long-term diet appears to have the largest effect to date. Recent research on the effects of dietary interventions has shown that the gut microbiome can change dramatically with diet; however, the gut microbiome is generally resilient, and short-term dietary intervention is not typically successful in treating obesity and malnutrition. Understanding the dynamics of the gut microbiome under different conditions will help us diagnose and treat many diseases that are now known to be associated with microbial communities.