  A KdV flow is constructed on a space whose structure is described in terms of
the spectrum of the underlying Schr\"odinger operators. The space includes the
conventional decaying functions and ergodic ones. Especially any smooth almost
periodic function can be initial data for the KdV equation.
