First-principles calculations based on density functional theory and the pseudopotential method have been used to investigate the energetics of H$_2$O adsorption on the (110) surface of TiO$_2$ and SnO$_2$. Full relaxation of all atomic positions is performed on slab systems with periodic boundary conditions, and the cases of full and half coverage are studied. Both molecular and dissociative (H$_2$O $rightarrow$ OH$^-$ + H$^+$) adsorption are treated, and allowance is made for relaxation of the adsorbed species to unsymmetrical configurations. It is found that for both TiO$_2$ and SnO$_2$ an unsymmetrical dissociated configuration is the most stable. The symmetrical molecularly adsorbed configuration is unstable with respect to lowering of symmetry, and is separated from the fully dissociated configuration by at most a very small energy barrier. The calculated dissociative adsorption energies for TiO$_2$ and SnO$_2$ are in reasonable agreement with the results of thermal desorption experiments. Calculated total and local electronic densities of states for dissociatively and molecularly adsorbed configurations are presented and their relation with experimental UPS spectra is discussed.