- Internet Protocols and Support in the standard library
The http.server
library can be used from the command line to serve
a local directory. To serve the current working directory on
http://localhost:8000
:
python3 -m http.server # 3.x
python -m SimpleHttpServer 8000 # 2.x