Significance
Exploring light dynamics and chaos on curved surfaces is one of the new challenges met in modern cosmology. To address this question and investigate chaotic dynamics of light on three-dimensional curved surfaces, we consider their connection under a conformal transformation with flat billiards with spatially varying refractive index. Through this connection, we demonstrate that these two systems share the same dynamics; the complexity of the problem simplifies, and well-known tools originating from chaos analysis in planar billiards can be used to explore chaotic dynamics on curved space. We discover that the degree of chaos is fully controlled by a single curvature-related geometrical parameter, providing a degree of freedom in chaos engineering, as well as potentialities to design nonuniform table billiards/cavities/resonators.