Possible Duplicate:
Python urllib vs httplib?
I am just curious when I would want to use httplib over urllib2 and vice versa.
Basically - httplib is lower level, while urllib is high-level. Use urllib2 whenever you just need to do something basic, like read the contents of a web site. Use httplib when you need to do something more crazy (hopefully rarely).