Monitoring changes of signaling molecules and metabolites with high temporal resolution is key to understanding dynamic biological systems. Here, we use directed evolution to develop a genetically encoded ratiometric biosensor for c-di-GMP, a ubiquitous bacterial second messenger regulating important biological processes like motility, surface attachment, virulence and persistence. The resulting biosensor, cdGreen2, faithfully tracks c-di-GMP in single cells and with high temporal resolution over extended imaging times, making it possible to resolve regulatory networks driving bimodal developmental programs in different bacterial model organisms. We further adopt cdGreen2 as a simple tool for in vitro studies, facilitating high-throughput screens for compounds interfering with c-di-GMP signaling and biofilm formation. The sensitivity and versatility of cdGreen2 could help reveal c-di-GMP dynamics in a broad range of microorganisms with high temporal resolution. Its design principles could also serve as a blueprint for the development of similar, orthogonal biosensors for other signaling molecules, metabolites and antibiotics.