Scope: Dysbiosis of gut microbiota is involved in metabolic syndrome (MetS) development, which has a different incidence between men (M) and women (W). The differences in gut microbiota in MetS patients are explored according to gender, and whether consuming two healthy diets, Mediterranean (MED) and low-fat (LF), may, over time, differentially shape the gut microbiota dysbiosis according to gender is evaluated. Materials and Methods: All the women from the CORDIOPREV study whose feces samples were available and a similar number of men, matched by the main metabolic variables (N = 246, 123 women and 123 men), and categorized according to the presence or not of MetS are included. Gut microbiota is analyzed at baseline and after 3 years of dietary intervention. Results: Higher abundance of Collinsella, Alistipes, Anaerotruncus, and Phascolarctobacterium genera is observed in MetS-W than in MetS-M, whereas the abundance of Faecalibacterium and Prevotella genera is higher in MetS-M than in MetS-W. Moreover, higher levels of Desulfovibrio, Roseburia, and Holdemania are observed in men than in women after the consumption of the LF diet. Conclusion: The results suggest the potential involvement of differences in gut microbiota in the unequal incidence of metabolic diseases between genders, and a sex-dependent effect on shaping the gut microbiota according to diet.