The best way to install a retaining wall is to first excavate and level the area where the wall will be built. Then, install a gravel base and compact it thoroughly. Begin laying the bottom row of blocks or stones, ensuring that they are level and tightly connected. Continue building up the wall, staggering the joints and backfilling with gravel or crushed stone as you go. Use a compactor to ensure that the wall is solid and stable. Finally, cap the top of the wall with capstones or coping stones to complete the installation.