In this work, dark Ti(OxH)y films were obtained by DC magnetron reactive sputtering under different oxygen partial pressures (PO2) starting from a high base pressure chamber atmosphere (10−5 mbar) with the purpose of investigating the visible light absorption dependence of the hydrogen content and stoichiometry. The TiOx film compositions, thicknesses, and elemental depth profiles were measured by ion beam analysis (IBA) techniques in a self-consistent approach. The optical properties were investigated by visible and near-infrared spectrophotometry, and the crystallography was examined by small-angle X-ray diffraction. The films deposited at a low PO2 were dark, and as the partial oxygen pressure increases, they became transparent. The IBA showed that the hydrogen content exponentially decreased as the PO2 increased. The optical constants for the films, n and k, are dependent on oxygen and hydrogen ratio as well as the optical band gap that can be modulated from 0.40 to 3.25 eV, and thus a significant improved PEC activity. These modulations may be useful for optical or electronic devices as a variable semiconductor or dielectric layer.