Back to the command reference

wget

NetworkBeginner In real Linux

Download files from the web

Name: wget = World Wide Web get

This command needs a real Linux system; you can practise it in real Linux mode.

Description

wget is a non-interactive downloader that saves files straight to disk. It shines with large downloads (resume with -c, automatic retries) and can mirror whole sites recursively. Compared with curl it focuses on downloading.

Syntax

wget [OPTION]... URL...

Common options

-O / --output-document FILESave under a given name
-P / --directory-prefix DIRSave into the directory DIR
-c / --continueResume a partial download
-q / --quietQuiet
-b / --backgroundDownload in the background (progress in wget-log)
-i / --input-file FILEDownload every URL listed in FILE
-r / --recursiveDownload recursively
--limit-rate RATELimit the speed, e.g. --limit-rate=200k
-t / --tries NUMRetry at most NUM times
-T / --timeout SECONDSTime-out in seconds
--spiderOnly check that the URL works; download nothing
--no-check-certificateDo not check the HTTPS certificate (testing only)

Examples

  • $ wget http://web01/files/data.csv

    Download a file into the current directory

    Explain
  • $ wget -c http://web01/files/report.txt

    Resume an interrupted download

    Explain

Related