We report the local oxidation of hydrogen terminated silicon (Si) surfaces induced with the scanning-tunneling microscope (STM) operating in air and by a beam of free low-energy electrons. With STM, oxide lines were written in Si(100) and Si(110) and transferred into the substrate by wet etching. In case of Si(110) trenches with a width as small as 35 nm and a depth of 300 nm were made. The same process has also successfully been applied to the patterning of hydrogenated amorphous silicon (a-Si:H) thin films. We demonstrate the fabrication of metallic ‘nanowires’ using a-Si:H as resist layer. With regard to the process of oxidation, it is found that the oxide written with STM is apparently not proportional to the electron current, in contrast to results obtained with a beam of free electrons in an oxygen gas-environment. The dose needed to remove the hydrogen was determined as a function of electron energy. This dose is minimal for 100 eV electrons amounting to 4 mC/cm2.