Skip to main content
skill CX Codex

download-gemini-images — Claude Code skill: pull images out of Gemini

This skill downloads images from an open Gemini chat through your logged-in Chrome session and packages them into a ZIP in thread order.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add daymade/claude-code-skills --skill download-gemini-images -a claude-code
Open on GitHub

What download-gemini-images does

It opens Gemini image lightboxes and grabs the larger displayed files rather than the thumbnail previews on the page. Everything runs through the Chrome plugin, because Gemini conversations normally need your existing Google session. A fresh unauthenticated browser gets you nowhere here.

The flow: the skill claims the Gemini tab you already have open, or opens the URL you provide, then imports scripts/download_gemini_images.mjs inside a node_repl session and starts the download. Files come out named in thread order — image_01.jpg, image_02.jpg, and so on. Packaging is handled by scripts/package_images.sh, which builds the ZIP, runs zip -T, and checks the archive holds the same ordered files as the directory.

If lightbox automation fails while the page is visibly loaded, there is a fallback through pageAssets. It usually returns 512px preview JPEGs instead of the larger lightbox files, and the skill tells you when it takes that route. Should Gemini ask for a login, the run pauses until you sign in through Chrome.

What it helps with

  • pull every image out of a long Gemini thread in one pass
  • get the larger displayed files instead of preview thumbnails
  • bundle the downloads into a ZIP that keeps thread order
  • rename files in sequence instead of leaving random download names
  • grab chat images without leaving your Google session

Example prompts for the agent

  • download all the images from this Gemini chat and zip them
  • export the images from gemini.google.com/app, I expect 20
  • save the images from my open Gemini tab in order

How to install download-gemini-images

1Skills CLI (Vercel)

npx skills add daymade/claude-code-skills --skill download-gemini-images -a claude-code

2Manually: put the files in place

~/.claude/skills/download-gemini-images/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/download-gemini-images/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about download-gemini-images

How do I install download-gemini-images in Claude?

Run npx skills add daymade/claude-code-skills --skill download-gemini-images -a claude-code. The skill lands at ~/.claude/skills/download-gemini-images/SKILL.md.

What does download-gemini-images do?

It downloads images from a Gemini conversation using your logged-in Chrome session, opening lightboxes to reach the larger files, and packages them into a ZIP named in thread order.

What happens if lightbox automation fails?

The skill falls back to pageAssets and collects previews. Those are usually 512px JPEGs rather than the larger lightbox files, and the skill reports that it used the fallback.

Source text

SKILL.md · MIT
---
name: download-gemini-images
description: Download, export, save, or package images from a Google Gemini conversation/chat/app page, especially uploaded images or generated image previews visible in a Gemini thread. Use when the task needs logged-in Chrome/Gemini state, opening Gemini image lightboxes, downloading the larger displayed image files, renaming them in order, and producing a ZIP archive.
---

# Download Gemini Images

## Overview

Download Gemini conversation images from the user's logged-in Chrome session. Prefer the lightbox image over thumbnail/page-preview assets because Gemini often exposes a larger `blob:` image only after the user opens a preview.

## Workflow

1. Use the Chrome plugin, not a fresh unauthenticated browser, because Gemini conversations usually require the user's existing Google session.
2. Bootstrap Chrome per the Chrome skill, claim the already-open Gemini tab if it exists, or open the user-provided Gemini URL in Chrome.
3. Import and run `scripts/download_gemini_images.mjs` from a `node_repl` JS call after `browser` is available.
4. Package the output directory with `scripts/package_images.sh`.
5. Report the ZIP path, image count, and any lower-resolution fallback.
6. Finalize Chrome control after downloads are complete, keeping the user's original Gemini tab open when appropriate.

## Main Script

Resolve the script path relative to this skill directory, then import it in the same Node REPL session used for Chrome automation:

```js
var { downloadGeminiImagesFromChrome } = await import("/absolute/path/to/download-gemini-images/scripts/download_gemini_images.mjs");
var result = await downloadGeminiImagesFromChrome({
  browser,
  tabUrlIncludes: "gemini.google.com/app",
  expectedCount: 20,
  outputDir: `${nodeRepl.homeDir}/Downloads/gemini_conversation_images_${new Date().toISOString().slice(0, 10).replaceAll("-", "")}`
});
nodeRepl.write(JSON.stringify(result, null, 2));
```

Set `expectedCount` only when the user gave a specific count. Omit it to download every visible `Show the uploaded image in a lightbox` button.

## Packaging

After the main script returns `outputDir`, run:

```bash
/absolute/path/to/download-gemini-images/scripts/package_images.sh "$outputDir" "$HOME/Downloads/gemini_conversation_images.zip"
```

The packaging script creates the ZIP, runs `zip -T`, and verifies that the archive contains the same ordered image files as the directory.

## Fallback

If lightbox automation fails but the page is visibly loaded, use the tab `pageAssets` capability:

```js
var pageAssets = await tab.capabilities.get("pageAssets");
var inventory = await pageAssets.list();
var uploaded = inventory.assets.filter(a => a.kind === "image" && a.url.includes("lh3.googleusercontent.com/gg/"));
var bundle = await pageAssets.bundle({ inventoryId: inventory.id, assetIds: uploaded.map(a => a.id) });
nodeRepl.write(JSON.stringify(bundle, null, 2));
```

This usually captures 512px preview JPEGs, not the larger lightbox files. Tell the user when this fallback is used.

## Notes

- Do not inspect browser cookies, local storage, passwords, or session stores.
- Downloading files is an inbound transfer and does not require confirmation by itself.
- If Gemini asks the user to log in, pause and ask the user to complete login in Chrome.
- If the user wants the images in the same order as the thread, use the script's ordered names: `image_01.jpg`, `image_02.jpg`, etc.

© daymade · MIT · daymade/claude-code-skills

Similar skills

All skills for Browser and scraping →

From the same set64

notify-wecom Sends a single one-off message to a WeCom (Enterprise WeChat) group bot. Handy when the team needs a quick ping without templates or setup. CX Codex +1 341installs setup-notifications-via-wecom Sets up a WeCom group bot webhook and sends technical status messages through it. Useful when a backup, sync or cron job should report on its own. CX Codex +1 341installs local-codex Runs the local OpenAI Codex CLI as a non-interactive sub-agent using ChatGPT OAuth. Ideal for offloading code generation and reviews without API keys. CX Codex +1 333installs wps-doc-scraper This skill archives public WPS/KDocs documents and embedded ProcessOn mind maps as raw data, SVG or PNG, and Markdown. Useful when a link has to be saved without logging in. CX Codex +1 334installs codex-image-gallery Launches a local browser gallery for reviewing Codex-generated images. Useful when you need to inspect local output folders without leaving your agent workflow. CX Codex +1 326installs openclaw-model-switch Safely switches or repairs OpenClaw model settings in openclaw.json. It handles primary model switches, routing errors, and token hijack bugs without breaking gateway sync. CX Codex +1 323installs claude-migrate-memory-to-doc Pulls your profile and preferences out of Claude's personal memory into documents that Claude, Cursor and other CLIs can read. CX Codex +1 325installs skill-governance Works out how many Skills the model actually sees, why the catalog is truncated, and which duplicates should go. Handy once your Skill list gets long. CX Codex +1 303installs

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor