The following method allows you to download Mac OS X Lion, Mountain Lion, and Mavericks. Start your Mac holding down Command + R. Prepare a clean external drive (at least 10 GB of storage). Within OS X Utilities, choose Reinstall OS X. Select external drive as a source. Enter your Apple ID. More @Wikipedia
Hover over any link to get a description of the article. Please note that search keywords are sometimes hidden within the full article and don't appear in the description or title.