Instaloader: Instagram Content Downloader Tool
Python CLI for downloading Instagram posts, stories, profiles, and metadata.
Learn more about Instaloader
Instaloader is a Python-based command-line utility that downloads Instagram content including photos, videos, stories, and associated metadata. The tool operates by interfacing with Instagram's web API to retrieve content and stores it locally with organized directory structures. It maintains session cookies for authentication, supports incremental updates, and automatically handles profile name changes. Common use cases include content archiving, OSINT investigations, social media research, and personal backup of Instagram accounts.
Metadata Preservation
Downloads complete post metadata including comments, geotags, captions, and timestamps alongside media files. Maintains data integrity for archival and analysis purposes.
Incremental Updates
Supports fast-update mode and timestamp tracking to resume interrupted downloads and sync only new content. Automatically detects profile name changes and updates directory structures.
Authentication Support
Handles both public and private Instagram profiles through session cookie management. Stores authentication tokens for non-interactive batch operations.
import instaloader
# Create an Instaloader instance
L = instaloader.Instaloader()
# Download profile posts
profile_name = "username"
try:
profile = instaloader.Profile.from_username(L.context, profile_name)
# Download all posts from the profile
for post in profile.get_posts():
L.download_post(post, target=profile_name)
print(f"Downloaded post: {post.shortcode}")
# Access metadata
print(f"Caption: {post.caption}")
print(f"Likes: {post.likes}")
print(f"Date: {post.date}")
except instaloader.exceptions.ProfileNotExistsException:
print(f"Profile {profile_name} does not exist")
except Exception as e:
print(f"Error: {e}")This release fixes critical download issues with Instagram security challenges and improves anonymous profile fetching capabilities.
- –Abort download, saving the resume iterator file, if a query is responded with feedbackrequired, checkpointrequired or challengerequired
- –Fix anonymous fetch of profile posts
- –Update Instagram iOS version headers based on one of the latest app version
- –Add Post.videoplaycount property
- –Update default user agent to Chrome/142
This release fixes issues with handling pinned posts when downloading Instagram reels.
- –Fix handling of pinned posts when downloading reels
This pre-release updates iPhone query headers and the default user agent, along with minor documentation improvements.
- –Update headers used for iPhone queries
- –Update default user agent
- –Minor improvements to the documentation
Top in Developer Tools
Related Repositories
Discover similar tools and frameworks used by developers
Selenium
Browser automation framework implementing W3C WebDriver with multi-language support.
Serena
Coding agent toolkit with semantic code retrieval and editing for LLMs via MCP server.
Mamba
Fast C++ reimplementation of conda with parallel downloading and improved dependency solving performance.
node-gyp
Compiles native C/C++ addons for Node.js.
Create T3 App
Interactive CLI for scaffolding typesafe Next.js applications with the T3 Stack technology combination.