A Django-based web application for easy file sharing on local networks or the internet. Designed for simplicity and large file support, with an admin panel for file management.
- Upload and share files of any type (up to 100GB per file by default)
- Public access: No login or signup required for users
- Short link generation for easy sharing
- File integrity verification (MD5, SHA256)
- Admin panel for managing files and short links
- Mobile-friendly interface
- QR code for quick access on phones
- Python 3.8+
- Django 5.x
- python-decouple
- (Optional) django-storages for cloud storage
-
Clone the repository:
git clone https://github.com/himanchalkaushale/File-Sharing-Django-Server.git cd File-Sharing-Web -
Create and activate a virtual environment:
python -m venv venv # Windows: venv\Scripts\activate # macOS/Linux: source venv/bin/activate
-
Install dependencies:
pip install -r requirements.txt
-
Configure environment variables:
- Copy
env_example.txtto.envand set yourSECRET_KEYand other settings as needed.
- Copy
-
Apply migrations:
python manage.py migrate
-
Create a superuser for the admin panel:
python manage.py createsuperuser
-
Run the development server:
python manage.py runserver 0.0.0.0:8000
- Access the site at
http://<your-ip>:8000/from any device on the same network. - Admin panel:
http://<your-ip>:8000/admin/
- Access the site at
- Uploaded files are stored in the
media/directory by default. - For production, configure cloud storage (e.g., Amazon S3) for persistent and scalable file storage.
- For public access, deploy to a cloud server (e.g., DigitalOcean, AWS EC2) or use a platform like Heroku (with external storage).
- Update
ALLOWED_HOSTSinsettings.pyfor your domain or server IP. - Use a production-ready web server (e.g., Gunicorn, Nginx).
- The public site has no authentication; anyone with the link can upload/download files.
- The admin panel is protected and requires a superuser login.
- Keep your
SECRET_KEYand credentials safe (do not commit them to GitHub).
- Access at
/admin/with your superuser account. - Manage files, short links, and view file integrity status.
MIT License
Contributions and feedback are welcome!