Nanowires have substantial potential as the sensor component in electronic sensing devices. However, surface functionalization of traditional nanowire and nanotube materials with short peptides that increase sensor selectivity and sensitivity requires complex chemistries with toxic reagents. In contrast, microorganisms can assemble pilin monomers into protein nanowires with intrinsic conductivity from renewable feedstocks, yielding an electronic material that is robust and stable in applications, but also biodegradable. Here we report that the sensitivity and selectivity of protein nanowire-based sensors can be modified with a simple plug and play genetic approach in which a short peptide sequence, designed to bind the analyte of interest, is incorporated into the pilin protein that is microbially assembled into nanowires. We employed a scalable Escherichia coli chassis to fabricate protein nanowires that displayed either a peptide previously demonstrated to effectively bind ammonia, or a peptide known to bind acetic acid. Sensors comprised of thin films of the nanowires amended with the ammonia-specific peptide had a ca. 100-fold greater response to ammonia than sensors made with unmodified protein nanowires. Protein nanowires with the peptide that binds acetic acid yielded a 4-fold higher response than nanowires without the peptide. The results demonstrate that protein nanowires with enhanced sensor response for analytes of interest can be fabricated with a flexible genetic strategy that sustainably eliminates the energy, environmental, and health concerns associated with other common nanomaterials.