The objective was to build an efficient algorithm (1) to estimate seismic velocity from time-migration velocity, and (2) to convert time-migrated images to depth. We established theoretical relations between the time-migration velocity and seismic velocity in two and three dimensions using paraxial ray-tracing theory. The relation in two dimensions implies that the conventional Dix velocity is the ratio of the interval seismic velocity and the geometric spreading of image rays. We formulated an inverse problem of finding seismic velocity from the Dix velocity and developed a numerical procedure for solving it. The procedure consists of two steps: (1) computation of the geometric spreading of image rays and the true seismic velocity in time-domain coordinates from the Dix velocity; (2) conversion of the true seismic velocity from the time domain to the depth domain and computation of the transition matrices from time-domain coordinates todepth. For step 1, we derived a partial differential equation (PDE) in two and three dimensions relating the Dix velocity and the geometric spreading of image rays to be found. This is a nonlinear elliptic PDE. The physical setting allows us to pose a Cauchy problem for it. This problem is ill posed, but we can solve it numerically in two ways on the required interval of time, if it is sufficiently short. One way is a finite-difference scheme inspired by the Lax-Friedrichs method. The second way is a spectral Chebyshev method. For step 2, we developed an efficient Dijkstra-like solver motivated by Sethian's fast marching method. We tested numerical procedures on a synthetic data example and applied them to a field data example. We demonstrated that the algorithms produce a significantly more accurate estimate of seismic velocity than the conventional Dix inversion. This velocity estimate can be used as a reasonable first guess in building velocity models for depth imaging.