Be aware that there are two kinds of gas blowback airsoft pistols. There is a group that is being powered by green gas and another one being powered by CO2. The method shown here to clean your GBB pistol works for all these differently powered systems.
The lifespan of these pistols, like any other gun, depends on the maintenance of its parts. Also the performance can be dramatically affected when not taking care of your airsoft pistol(s). Especially airsoft gas blowback systems are fragile when not properly being taken care of. So make sure to clean your GBB pistol right.
The frequency for cleaning your airsoft pistol depends on where you usually use it. To determine how often you should clean your pistol, simply attend about 3 days of airsoft games or training sessions and clean it afterwards. When you notice a difference in the smoothness of your slide than you know it was useful. If not stretch the period a bit more until you find your own time-lapse.