I only pull the skimmer basket out with the pump off. The less debris going down the skimmer line and through the impeller, the better.
I usually reach into the skimmer basket with the pump on and scoop out debris in there. It is never perfect, but it is good enough as the skimmer basket will...