Molecules that change color can be used to follow in real-time how bacteria form a protective biofilm around themselves. This new method may in the future become significant both in medical care and the food industry, where bacterial biofilms are a problem.