The gut microbiotas of cockroaches and termites play important roles in the symbiotic digestion of dietary components, such as lignocellulose. Diet has been proposed as a primary determinant of community structure within the gut, acting as a selection force to shape the diversity observed within this "bioreactor", and as a key factor for the divergence of the termite gut microbiota from the omnivorous cockroach ancestor. The gut microbiota in most termites supports primarily the breakdown of lignocellulose, but the fungus-farming sub-family of higher termites has become similar in gut microbiota to the ancestral omnivorous cockroaches. To assess the importance of a fungus diet as a driver of community structure, we compare community compositions in the guts of experimentally manipulated Pycnoscelus surinamensis cockroaches fed on fungus cultivated by fungus-farming termites. MiSeq amplicon analysis of gut microbiotas from 49 gut samples showed a step-wise gradient pattern in community similarity that correlated with an increase in the proportion of fungal material provided to the cockroaches. Comparison of the taxonomic composition of manipulated communities to that of gut communities of a fungus-feeding termite species showed that although some bacteria OTUs shared by P. surinamensis and the farming termites increased in the guts of cockroaches on a fungal diet, cockroach communities remained distinct from those of termites. These results demonstrate that a fungal diet can play a role in structuring gut community composition, but at the same time exemplifies how original community compositions constrain the magnitude of such change.