Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

In my office I want to update and download through wget and here they are using a proxy. How can I get wget to use the proxy from the command-line?

share|improve this question
The title references apt-get but the question is about wget. Which one of the two are you interested in? – Riccardo Murri Oct 15 '10 at 14:51

Either export the http_proxy environment variable as in export http_proxy=http://myproxy:port or add

Acquire::http::proxy "http://MYNAME:MYPASS@MY.PROXY.COM:MYPORT"

To /etc/apt/apt.conf.

See http://ubuntuforums.org/showthread.php?t=96802

share|improve this answer
Acquire::http::Proxy "MYDOMAIN\MYNAME:MYPASS@MY.PROXY.COM:MYPORT" correct? – Renjith G Oct 15 '10 at 11:41
Don't know, depends on your proxy and how it works. – tante Oct 15 '10 at 11:45
:-( , I am getting error "Access to web proxy service denied!" – Renjith G Oct 15 '10 at 11:51

If your machine is behind a proxy running a Microsoft NTLM based web proxy you may need something like the (python based) ntlmaps to sit between wget/apt-get and the real proxy to do the authentication for you.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.