We investigate the cosmological evolution for the physical parameters in Weyl integrable gravity in a Friedmann–Lemaître–Robertson–Walker universe with zero spatial curvature. For the matter component, we assume that it is an ideal gas, and of the Chaplygin gas, from the Weyl integrable gravity a scalar field is introduced by a geometric approach which provides an interaction with the matter component.We calculate the stationary points for the field equations and we study their stability properties. Furthermore, we solve the inverse problem for the case of an ideal gas and prove that the gravitational field equations can follow from the variation of a Lagrangian function. Finally, variational symmetries are applied for the construction of analytic and exact solutions.