To successfully colonize a host or environment, certain genera and species of Gram-positive bacteria have evolved to utilize the so-called sortase-dependent pilus, a long multi-subunit and non-flagellar surface adhesin. One example of this is Lactobacillus rhamnosus GG, a gut-adapted probiotic strain that produces SpaCBA pili. These structures are covalent hetero-oligomers built from three types of pilin subunit, each with a specific location and function (i.e., backbone SpaA for length, tip SpaC for adhesion, and basal SpaB for anchoring). Functionally, the SpaCBA pilus exhibits a promiscuous affinity for components on intestinal surfaces (e.g., mucus, collagen, and epithelial cells), which is largely attributed to the SpaC subunit. Then again, the basal SpaB pilin, in addition to acting as the terminal subunit during pilus assembly, displays an out of character mucoadhesive function. To address the structural basis of this unusual dual functionality, we reveal the 2.39 Å resolution crystal structure of SpaB. SpaB consists of one immunoglobulin-like CnaB domain and contains a putative intermolecular isopeptide bond-linking lysine and internal isopeptide bond-asparagine in an FPKN pilin motif within the C-terminal end. Remarkably, we found that a C-terminal stretch of positively charged lysine and arginine residues likely accounts for the atypical mucoadhesiveness of SpaB. Although harboring an autocatalytic triad of residues for a potential internal isopeptide interaction, the SpaB crystal structure lacked the visible electron density for intact bond formation, yet its presence was subsequently confirmed by mass spectral analysis. Finally, we propose a structural model that captures the exclusive basal positioning of SpaB in the SpaCBA pilus.