We propose theoretically a method that allows to measure all the components of the quantum geometric tensor (the metric tensor and the Berry curvature) in a photonic system. The method is based on standard optical measurements. It applies to two-band systems, which can be mapped to a pseudospin, and to four-band systems, which can be described by two entangled pseudospins. We apply this method to several specific cases. We consider a 2D planar cavity with two polarization eigenmodes, where the pseudospin measurement can be performed via polarization-resolved photoluminescence. We also consider the s band of a staggered honeycomb lattice with polarization-degenerate modes (scalar photons), where the sublattice pseudospin can be measured by performing spatially resolved interferometric measurements. We finally consider the s band of a honeycomb lattice with polarized (spinor) photons as an example of a four-band model. We simulate realistic experimental situations in all cases. We find the photon eigenstates by solving the Schrödinger equation including pumping and finite lifetime, and then simulate the measurements to finally extract realistic mappings of the k-dependent tensor components.