The strong peristaltic contraction of the stomach facilitates mixing and emptying of ingested food, which occurs rhythmically at approximately 3 cycles/min (cpm) in humans. Generally, most patients with gastroparesis show gastric electrical dysrhythmia that is disrupted electrical signals controlling gastric contractions. For treatment of gastric electrical dysrhythmia, in vivo electrical impulses to the stomach via an implanted gastric stimulator have been known to restore these gastric deformations. Nevertheless, improved sensors to monitor gastric contractions are still needed in current gastric stimulators. Recently, we have developed a new technology converting mechanical motion to electrical energy by using stretch-induced capacitance changes of a coiled carbon-nanotube (CNT) yarn. For its potential use as a gastric deformation sensor, the performance of a coiled CNT yarn was evaluated in several biological fluids. For a sinusoidal stretch to 30%, the peak-to-peak open-circuit voltage (OCV) was consistently generated at frequencies below 0.1 Hz. This sinusoidal variation in OCV augmented as the strain increased from 10 to 30%. In an in vitro artificial gastric system, the OCV was approximately linearly proportional to the balloon volume, which can monitor periodic deformations of the balloon at 2, 3, and 4 cpm as shown for human gastric deformations. Moreover, stretchy coiled yarns generate the peak electrical voltage and power when deformed. The present study shows that a self-powered CNT yarn sensor can not only monitor the changes in frequency and amplitude of volumetric change but also generate electrical power by periodic deformations of the balloon. Therefore, it seems possible to automatically deliver accurate electrical impulses according to real-time evaluation of a patient’s gastric deformation based on information on the frequency, amplitude, and rate of the OCV from CNT yarn.