In this work, a flexible self-powered ammonia (NH3) sensing system based on a vertical contact-separate mode triboelectric nanogenerator (TENG) has been proposed for room temperature detection of NH3 concentrations. By integrating NH3-sensing materials into the nanogenerator (TENG), the degree of ambient NH3 concentration can be actively detected at room temperature. The output voltage of the self-powered system has a proportional relationship with NH3 concentrations. Furthermore, the Ce-ZnO heterostructure nanoparticles thin film was prepared by hydrothermal synthesis method under 150°C and then form a sensitive film through spray method, which demonstrates a good sensing-response when exposed to NH3 molecules. For comparison, the ZnO nanoparticles was prepared through the same method. Moreover, the morphology and chemical properties of the fabricated sensor based on ZnO nanoparticles and Ce-ZnO heterostructure nanoparticles film were characterized by SEM, UV-visible spectroscopy and XRD, respectively. In addition, the prepared self-powered triboelectric NH3 sensor based on Ce-ZnO heterostructure nanoparticles composite thin film holds a gas-sensing response of 44.68% at 100 ppm NH3. The doping of Ce in the hydrothermal synthesis process of ZnO nanoparticles effectively enhanced the active sites of ZnO, leading to an increase of the NH3-sensing response compared to pure ZnO nanoparticles film, which is 4.4 times higher than that of pure ZnO. This research not only provides a simple method in self-powered NH3 sensing but also successfully realizes the integration of NH3-sensitive materials in the TENG to achieve integrated compatibility in NH3 detection.