A novel method for in situ measurement of the static and kinetic friction is developed and demonstrated for zinc oxide nanowires (NWs) on oxidised silicon wafers. The experiments are performed inside a scanning electron microscope (SEM) equipped with a nanomanipulator with an atomic force microscope tip as a probe. NWs are pushed by the tip from one end until complete displacement is achieved, while NW bending is monitored by the SEM. The elastic bending profile of a NW during the manipulation process is used to calculate the static and kinetic friction forces.