Search⌘ K
AI Features

Downloading Files

Explore how to download files using the command-line interface with curl. Understand using redirection to save outputs, specifying file names, and handling URL redirects for reliable file transfers.

Downloading files using CLI

Let’s look at how we can download files using the CLI.

Instead of displaying the response to the screen, we can use the redirection symbol (>) to push that content into a text file. We can grab a copy of the HTML response from Google this way:

curl
...