A Python script to download videos from any Instagram account and upload them to your own account using Instaloader
and Instagrapi
.
- Download Videos: Fetch all videos from a specified Instagram user 📸.
- Upload Videos: Post downloaded videos to your Instagram account 📤.
- Retry Failed Uploads: Automatically retry uploads that failed 🚀.
- Account Status Check: Optional function to verify account status (if applicable) ✅.
-
Clone the Repository:
git clone https://github.com/yourusername/instagram-video-upload-download.git cd instagram-video-upload-download
-
Create a Virtual Environment (optional but recommended):
python -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate
-
Install Dependencies:
pip install -r requirements.txt
-
Configure Environment Variables:
Copy
.env.example
to.env
and update it with your Instagram credentials and user ID:cp .env.example .env
-
Run the Script:
instagram-video-upload-download.py
-
Update
instagram-video-upload-download.py
:- Replace placeholders in the
.env
file with your Instagram username, password, and target user ID.
- Replace placeholders in the
-
Run the Script:
- Ensure you have the necessary permissions and that your Instagram account is not restricted.
Contributions are welcome! Please submit a pull request with your changes.
This project is licensed under the MIT License - see the LICENSE file for details.
- Instaloader for video downloading 🎥.
- Instagrapi for video uploading 📤.