The spin-independent and transversity generalized form factors (GFFs) of the ϕ meson are studied using lattice QCD calculations with light quark masses corresponding to a pion mass m π ∼ 450ð5Þ MeV. One transversity and three spin-independent GFFs related to the lowest moments of leading-twist spinindependent and transversity gluon distributions are obtained at six nonzero values of the momentum transfer up to 1.2 GeV 2 . These quantities are compared with the analogous spin-independent quark GFFs and the electromagnetic form factors determined on the same lattice ensemble. The results show quantitative distinction between the spatial distribution of transversely polarized gluons, unpolarized gluons, and quarks and point the way towards further investigations of the gluon structure of nucleons and nuclei.