Total-energy pseudopotential calculations are used to study the imaging process in noncontact atomic-force microscopy on Si ~111! surfaces. At the distance of closest approach between the tip and the surface, there is an onset of covalent chemical bonding between the dangling bonds of the tip and the surface. Displacement curves and lateral scans on the surface show that this interaction energy and force are comparable to the macroscopic Van der Waals interaction. However, the covalent interaction completely dominates the force gradients probed in the experiments. Hence, this covalent interaction is responsible for the atomic resolution obtained on reactive surfaces and it should play a role in improving the resolution in other systems. Our results provide a clear understanding of a number of issues such as ~i! the experimental difficulty in achieving stable operation, ~ii ! the quality of the images obtained in different experiments and the role of tip preparations and ~iii ! recently observed discontinuities in the force gradient curves. @S0163-1829 ~98!08336-2#