The atomic structure of gallium arsenide and indium phosphide (001) surfaces in the metalorganic chemical vapor deposition (MOCVD) environment has been characterized in situ by scanning tunneling microscopy and infrared spectroscopy. During growth at V/III ratios above 10, these films exhibit similar surface structures. They are terminated with alkyl groups, hydrogen atoms and group V dimers (As or P) adsorbed on top of a complete layer of group V atoms. As the V/III ratio decreases, the exposed arsenic and phosphorous atoms desorb from the surface. On gallium arsenide, this occurs through a phase transition, involving gallium out-diffusion and surface roughening. By contrast, on InP, the underlying phosphorous atoms simply form rows of dimers, yielding a smooth, continuous layer.