Field-effect transistors have emerged as NO2 sensors. The detection relies on trapping of accumulated electrons, leading to a shift of the threshold voltage. To determine the location of the trapped electrons we have delaminated different semiconductors from the transistors with adhesive tape and measured the surface potential of the revealed gate dielectric with scanning Kelvin probe microscopy. We unambiguously show that the trapped electrons are not located in the semiconductor but at the gate dielectric. The microscopic origin is discussed. Pinpointing the location paves the way to optimize the sensitivity of NO2 field-effect sensors.