  We present the first cosmological constraints using only the observed
photometry of galaxies. Villaescusa-Navarro et al. (2022; arXiv:2201.02202)
recently demonstrated that the internal physical properties of a single
simulated galaxy contain a significant amount of cosmological information.
These physical properties, however, cannot be directly measured from
observations. In this work, we present how we can go beyond theoretical
demonstrations to infer cosmological constraints from actual galaxy observables
(e.g. optical photometry) using neural density estimation and the CAMELS suite
of hydrodynamical simulations. We find that the cosmological information in the
photometry of a single galaxy is limited. However, we combine the constraining
power of photometry from many galaxies using hierarchical population inference
and place significant cosmological constraints. With the observed photometry of
$\sim$20,000 NASA-Sloan Atlas galaxies, we constrain $\Omega_m =
0.323^{+0.075}_{-0.095}$ and $\sigma_8 = 0.799^{+0.088}_{-0.085}$.
