#! usr/bin/python #coding=utf-8 import urllib2 fp = open('test', 'wb') req = urllib2.urlopen('http://192.168.230.138/index.zip') for line in req: if not line: break fp.write(line) fp.close()