Cut off as much of the agave plant as possible, using pruners to reduce its size. This will make it easier to lift out the plant and reduce the chance of getting hurt by the large spikes.
Put the tip of the shovel into the ground a few inches from the base of the agave plant. Push down firmly to get a few inches under ground. Lift up the shovel, and the plant should begin to move upward.
Dig around the plant. Lift the plant itself upward with the shovel underneath. When the plant is free carefully move the plant portion out of the way using heavy work gloves.
Inspect the surrounding area for remaining roots and dig them out of the ground with the shovel. The roots can vary in size and length, so you may need to dig around the outside area of the hole created by removing the plant.
Locate large roots that you cannot easily remove. Split them open with a knife. Spray a small amount of glyphosate herbicide into the split to kill off the remaining roots. Spray a small amount of the herbicide in the surrounding soil.