We show that the Kaluza–Klein (KK) theory contains a fundamental problem: The four-dimensional metric tensor and the electromagnetic potential vector assumed in the KK theory belong to four-dimensional vector spaces that are not integrable in general, resulting that the four-dimensional physical variables and the corresponding field equations derived from the five-dimensional Einstein field equation (i.e. the four-dimensional Einstein field equation and the Maxwell equations) are not defined on a four-dimensional submanifold. That is, the four-dimensional spacetime assumed in the KK theory does not exist. No satisfactory solutions are found within the KK formalism. Perhaps the best approach to fix the problem is giving up the KK theory and looking for a new unified scheme for gravitational and electromagnetic interactions in the framework of a spacetime with extra dimensions, as having already been explored in some literature.