Inverse opal colorimetric sensors operating on wetting transitions usually rely on physical differences of the infiltrating liquid. Here, we exploit a reactive surface chemistry that changes wettability upon binding of an analyte. Upon binding of Fe3+ to a Schiff base immobilized on the porous structure, the surface becomes more hydrophilic, triggering the infiltration of the structure and causing the structural color to disappear.