Coherency inversion, which consists of maximizing a semblance function calculated from unstacked seismic waveforms, has the potential of estimating reliable velocity information without requiring traveltime picking on unstacked data.In this work, coherency inversion is based on the assumption that reflectors' zero-offset times are known and that the velocity in each layer may vary laterally. The method uses a type of Monte Carlo technique termed the generalized simulated annealing method for updating the velocity field. At each Monte Carlo step, time-to-depth conversion is performed. Although this procedure is slow at convergence to the global minimum, it is robust and does not depend on the initial model or topography of the objective function. Applications to both synthetic and field data demonstrate the efficiency of coherency inversion for estimating both lateral velocity variations and interface depth positions.