In this work, we consider the possibility of energy release in pulsar magnetospheres deformed by gravitational waves from nearby sources. The strong electromagnetic fields in the magnetospheres may release non-negligible energy despite the weakness of the gravitational wave. When the background spacetime is perturbed due to the passage of a gravitational wave, the original force-free state of the inner magnetosphere will be slightly violated. The plasma-filled magnetosphere tends to evolve into new force-free states as the spacetime varies with time. During this process, a small portion of the electromagnetic energy stored in the magnetosphere will be released to the acceleration of charged particles along the magnetic field lines. When the pulsar is close enough to the gravitational wave source (e.g., $sim10^{-2}$ pc to the gravitational wave sources observed recently), the resulting energy loss rate is comparable with the radio luminosity of the pulsar. It is also noticed that, under very stringent conditions (for magnetars with much shorter distance to the sources), the released energy can reach the typical energy observed from fast radio bursts (FRBs).