Skip to content

abishes/filesharing_with_http

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Python HTTP File Sharing Application

A simple local file sharing Python HTTP server for uploading and downloading files directly through a browser.
Runs in the current working directory, serving files and accepting uploads using a minimal web interface.


Features

  • Upload multiple files through a web form.
  • Download files stored in a directory where script is ran by clicking links.
  • Simple HTML interface for uploading and browsing files.
  • Saves uploaded files to the same directory where the script is ran.
  • Automatically shows the IP address the server is hosted on.
  • No external dependencies required.
  • Easy to run and customize.

How It Works

  • The server serves an HTML page with:
    • A file upload form allowing multiple files to be selected.
    • A list of uploaded files with clickable links for download.
  • Files uploaded via POST requests are saved in the directory where script is ran.
  • Files can be downloaded by clicking their links.

Setup and Usage

  1. Clone or download the repository.

  2. Navigate in your terminal to the directory where you want to upload and serve files, then Run the server:

    python fileshare.py

Upload & Download Instructions

If Server and Client are on the Same Network

  1. Make sure the server (running fileshare.py) is started on a machine connected to the network.
  2. On the client device (computer, phone, etc.) connected to the same network, open a browser.
  3. Enter the server’s IP address and port in the browser address bar, for example: 192.168.1.60:8000
  4. You will see the upload form and file list.
  5. Use the form to upload files, and click file links to download.

If Server and Client are NOT on the Same Network

  1. Use your phone or one device as a Wi-Fi hotspot.
  2. Connect both the server machine(or could be same device hosting hotspot) and the client device to this hotspot network.
  3. Find the IP address and port of the server machine on the hotspot network is provided by the script.
  4. On the client device, open a browser and go to address provided by script
  5. Upload and download files as usual.

Notes

  • Ensure firewalls or security software allow traffic on port.
  • The server IP must be reachable from the client device.
  • This method works well for quick local file sharing without internet.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published