instaloader
downloads pictures, videos, captions, and metadata from Instagram profiles
TLDR
SYNOPSIS
instaloader [options] target
DESCRIPTION
instaloader downloads pictures, videos, captions, and metadata from Instagram profiles. It can archive complete profiles including posts, stories, IGTV, and highlights.Targets can be profile names, hashtags ("#tag"), location IDs (%id), or the special selectors :feed, :stories, :saved. Prefixing a profile with @ downloads its list of followees instead. For best quality media and access to private profiles or stories, login credentials are required. Downloaded content includes metadata like captions, comments, and geolocation when available.
PARAMETERS
-l, --login USER
Log in as USER. Prompts for the password interactively and caches the session locally.-p, --password PASS
Supply the password on the command line. Discouraged: leaks into shell history and process list; prefer the interactive prompt.-f, --sessionfile FILE
Read/write the session cookie from/to FILE instead of the default location.--load-cookies BROWSER
Import the Instagram cookies of an already-logged-in browser (e.g. firefox, chrome).-s, --stories
Also download stories of every listed target (requires login).--igtv
Also download IGTV/Reel videos.--highlights
Download story highlights.-G, --geotags
Save geotag information as .txt alongside posts.-F, --fast-update
Stop iterating a target once the first already-downloaded item is reached.--post-filter EXPR, --only-if EXPR
Python expression evaluated per post (e.g. `--post-filter=viewerhasliked`); only matching posts are downloaded.--storyitem-filter EXPR
Same, applied to story items.--no-pictures, --no-videos, --no-captions, --no-metadata-json, --no-profile-pic, --no-posts
Opt out of individual content types.--dirname-pattern PATTERN, --filename-pattern PATTERN
Customize output paths using Python format strings.-q, --quiet
Suppress interactive prompts and progress messages.--user-agent UA
Send a custom HTTP User-Agent header.
INSTALL
CAVEATS
Instagram may rate-limit or block accounts making many requests. Login credentials are required for stories, private profiles, and full-quality downloads. Instagram's terms of service may restrict automated downloading.
HISTORY
instaloader was created as a Python tool for archiving Instagram content. It provides a legal means to download your own content or public profiles for personal use.
SEE ALSO
youtube-dl(1), gallery-dl(1)
