Structural and dynamical properties of hydrogen in crystalline and amorphous silicon are analyzed by ab initio molecular dynamics simulations. In the crystalline case we focus mainly on the diffusion process of an isolated positively charged hydrogen impurity at high temperature, finding important dynamical effects. In the amorphous case we analyze the local order and the dynamical properties corresponding to an atomic hydrogen concentration of ~11%, typical of a device quality material. We find that hydrogen atoms form monohydride complexes and show interesting clustering effects. In both crystalline and amorphous cases, our results are in good agreement with available experimental data and give unique insight into the microscopic details of hydrogen incorporation in silicon. © 1991.