Uropathogenic Escherichia coli (UPEC) is the primary cause of community-acquired urinary tract infections (UTIs). UPEC bind the bladder using type 1 pili, encoded by the fim operon in nearly all E. coli. Assembled type 1 pili terminate in the FimH adhesin, which specifically binds to mannosylated glycoproteins on the bladder epithelium. Expression of type 1 pili is regulated in part by phase-variable inversion of the genomic element containing the fimS promoter, resulting in phase ON (expressing) and OFF (nonexpressing) orientations. Type 1 pili are essential for virulence in murine models of UTI; however, studies of urine samples from human UTI patients demonstrate variable expression of type 1 pili. We provide insight into this paradox by showing that human urine specifically inhibits both expression and function of type 1 pili. Growth in urine induces the fimS phase OFF orientation, preventing fim expression. Urine also contains inhibitors of FimH function, and this inhibition leads to a further bias in fimS orientation toward the phase OFF state. The dual effect of urine on fimS regulation and FimH binding presents a potential barrier to type 1 pilus-mediated colonization and invasion of the bladder epithelium. However, FimH-mediated attachment to human bladder cells during growth in urine reverses these effects such that fim expression remains ON and/or turns ON. Interestingly, FimH inhibitors called mannosides also induce the fimS phase OFF orientation. Thus, the transduction of FimH protein attachment or inhibition into epigenetic regulation of type 1 pilus expression has important implications for the development of therapeutics targeting FimH function.IMPORTANCE Urinary tract infections (UTIs) are extremely common infections, frequently caused by uropathogenic Escherichia coli (UPEC), that are treated with antibiotics but often recur. Therefore, UTI treatment both is complicated by and contributes to bacterial antibiotic resistance. Thus, it is important to understand UTI pathogenesis to devise novel strategies and targets for prevention and treatment. Based on evidence from disease epidemiology and mouse models of infection, UPEC relies heavily on type 1 pili to attach to and invade the bladder epithelium during initial stages of UTI. Here, we demonstrate that the negative effect of planktonic growth in human urine on both the function and expression of type 1 pili is overcome by attachment to bladder epithelial cells, representing a strategy to subvert this alternative innate defense mechanism. Furthermore, this dually inhibitory action of urine is a mechanism shared with recently developed anti-type 1 pilus molecules, highlighting the idea that further development of antivirulence strategies targeting pili may be particularly effective for UPEC.