Optical metasurfaces use nanoscale structures to confine light and tailor its interaction with matter. I will introduce the underlying resonance physics and show how these concepts enable molecular sensing and dynamic control of optical responses using tunable materials.