First you have to install Ruby in your system. Go to this link and choose your operating system and install Ruby into your system.
After installing ruby install wayback machine site download script by using your command prompt or terminal
gem install wayback_machine_downloader
Your system is ready to download sites from archive.org website. Now browse your site in archive.org website. Say your website link in archive.org is
Now in the terminal or command prompt you have to type
wayback_machine_downloader http://yoursite.com --to 20050123211609
System will download all the files and save it in your pc or system. In the terminal you can see where the file is saving.
More details will be found in this github link