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

I downloaded a website using:

wget -c --mirror -p http://www.somewebsite.com

for offline viewing and I just remembered that I forgot the --convert-links option! They are all on my hard drive right now. Is there a way to do --convert-links without redownloading the whole website?

share|improve this question

Straightforward one: serve local directory with something like SimpleHTTPServer, then re-wget from localhost with appropriate options.

share|improve this answer
Quite a good idea, why the down vote? – phunehehe Feb 14 '11 at 9:32
I should add that one shout edit /etc/hosts to fake localhost as the website being mirrored. And this will only work well if the links all point to the same webpage (i.e no hot-linked images). – phunehehe Feb 14 '11 at 9:34
What is SimpleHTTPServer? Is it the Python module? If so, can you show how to use it (so I can revoke my careless downvote). – Tshepang Feb 14 '11 at 13:01
@Tshepang Yes Python is pretty awesome with the huge load of modules :) SimpleHTTPServer is my favorite – phunehehe Feb 14 '11 at 15:10

Also, don't forget to use the option --timestamping, or add timestamping=on to "~/.wgetrc". It ensures that when you re-mirror the website, you don't re-download the whole website, but only changed/new files. See the section Time-Stamping in manpage of wget for more.

FWIW I use this to mirror my blog:

wget --mirror --adjust-extension --convert-links --no-cookies --timestamping http://example.com --output-file=log-blog

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.