Use a 3-inch thick rope or strip of thick cloth to remove the squirrel out of the vent pipe. Tie knots, 12 inches apart, all across the rope, to provide a secure foothold for the squirrel while climbing.
Tie a small heavy object, such as a pair of pliers to the end of the rope. Tying a heavy object will give you an indication of when the rope touches the bottom of the vent pipe.
Lower the end of the rope on which the pliers are fixed, slowly down the vent pipe. Ensure that the rope touches the bottom of the vent pipe. Secure the other end of the rope around the top portion of the vent pipe.
Wait for the squirrel to climb out of the vent pipe. The squirrel will use the rope to climb out within a time span of 24 hours.
Fix a 1/4-inch hardware cloth around the vent pipe once the squirrel has gone out. This will prevent it from reentering the vent pipe.