We consider a model of a light-matter system, in which a system of fermions (or bosons) is coupled to a photonic mode that drives a phase transitions in the matter degrees of freedom. Starting from a simplified analytical model, we show that the entanglement between light and matter vanishes at small and large coupling strength, and shows a peak in the proximity of the transition. We perform numerical simulations for a specific model (relevant to both solid state and cold atom platforms), and show that the entanglement displays critical behavior at the transition, and features maximum susceptibility, as demonstrated by a maximal entanglement capacity. Remarkably, light-matter entanglement provides direct access to critical exponents, suggesting a novel approach to measure universal properties without direct matter probes.