Making full use of high fiber and low-cost crop coproducts is helpful to alleviate the situation of people and livestock competing for crops. Digestion of dietary fibers in pigs is mainly through microbial fermentation in the large intestine. To reveal microbiota related to fiber digestion in pigs, fecal samples have been collected from 274 healthy female Suhuai pigs at 160 days of age under the same feeding conditions and have measured apparent neutral detergent fiber (NDF) and acid detergent fiber (ADF) digestibility. Samples from Suhuai pigs with extreme high and low apparent NDF digestibility and extreme high and low apparent ADF digestibility were subjected to shotgun metagenomic sequencing. At the species level, 62 microbial species in H_NDF group and 54 microbial species in H_ADF group were related to high fiber digestibility. Among them, Lachnospiraceae bacterium 3-1 and Alistipes sp. CAG:514 may be new types of microorganisms associated with fiber digestion. In addition, we found that more abundant GH5 and GH48 family (contribute to cellulose degradation) genes, GH39 and GH53 family (contribute to hemicellulose degradation) genes in microorganisms may contribute to the higher apparent NDF digestibility of pigs, and more abundant GH3 and GH9 family (contribute to cellulose degradation) genes in microorganisms may contribute to the higher apparent ADF digestibility of pigs. The abundance of AA4 family (helps in lignin degradation) genes in H_NDF and H_ADF groups was significantly higher than that in L_NDF and L_ADF groups, respectively (P < 0.05). Three pathways in H_NDF group and four pathways in H_ADF group are important pathways associated with degradation of non-starch polysaccharides, and their relative abundance is significantly higher than that in L_NDF and L_ADF groups, respectively. Gut microbiota of Suhuai pigs with high apparent fiber digestibility had higher abundance of genes and microbiota related to fiber digestion and may have stronger fiber digestion potential compared with low apparent fiber digestibility group. This study revealed that the characteristics of gut microbiota and microbial gene functions of pigs with high fiber apparent digestibility, which provided a theoretical basis and reference for further understanding the impact of gut microbiota on fiber digestibility of pigs.