A mechanical license grants an artist permission to record or reproduce another artist's copyrighted music for sale or distribution. For example, purchasing a mechanical license will legally cover an artist to record and distribute a cover of another artist's song, but cannot be used in the case of sampling, editing or changing the original work.
Mechanical Licenses can be purchased from the owner or rights holder (i.e. music publisher of the original songwriter/s) of the song you wish to cover, or from an agency that represents a larger group of publishers. In the U.S. you can purchase a mechanical license from The Harry Fox Agency.