Skip to content

Userscript to Super-charge Google images with rich features, like: download all full-resolution images, replace thumbnails with full-res images, add "view image" and "download" buttons and much more

License

Notifications You must be signed in to change notification settings

FarisHijazi/SuperGoogleImages

Repository files navigation

SuperGoogleImages: a browser addon for Google Images

A browser-plugin/script to add features to Google images.

Key features:

  • Download all full quality images in a single click (as zip or individually)
  • Bring back the old view image button! (Now you won't have to visit the website just to see the fullres image)
  • Add download button Directly download the image
  • Replace thumbnails with full resolution images. (also animates all GIFs)
  • replace google redirect links

All features


WARNING: everything is very experimental up till now, there is a major reboot coming soon of the script. Thanks to Google for changing their HTML every few months and making life difficult.

Also most of the features listed bellow are actually not working anymore

Other similar and promising projects:

I am also working on reverse engineering extracting the links for the full resolution images


Installation

UserScript (Tampermonkey)

  1. Install Tampermonkey for your browser (or any UserScript client).
  2. Click DOWNLOAD (or visit the RAW file url).
  3. Allow downlaods. (Optional) (Click to expand)
    • Enable Browser API.
      enable browser API beta

      • Go to the Tampermonkey options page
      • Scroll down to the Downloads section
      • Double-check the Whitelisted File Extensions setting to not contain file extensions of executable files
      • Select Browser API at the Download Mode option
      • A notification may come up, you need to click at it and to click confirm at the permission grant dialog
    • When prompted, allow the script to load images, click Always allow all domains (only needed once).
      allow connect permissions
  4. Open any google image search page and press on the button "Display originals" at the top (or hold Ctrl and hover over the images with your mouse)

On mobile

for mobile, download a browser that supports the tampermonkey addon like kiwibrowser and follow the same steps above

Browser extension

Not yet supported, but coming soon!

Usage

Below is a list of the available features, sorted by most useful first.

Download all the images

You can download all the loaded images as a zip file or indipendantly (although this option is not advised due to it causing crashes).
You can even specify the minimum dimension for images using the sliders (to only download large images for example).

Display original images

One of the most important features, replaces thumbnails with the original source images, even GIFs!

original images

Enhance the image panels

Adds the following features to the image panel:

image panel screenshot

  • 1 - Add view image button

    Bring back the old view image button! Now you won't have to visit the website just to see the fullres image.

  • 2 - download button

    Directly download the image

  • 3 - Clickable description

    Lookup the description text, open another Google images page searching for the description text

  • 6 - Clickable image host text

    Click the image host to search google for more images from that site. For example if it was hosted by example.com, then clicking it would open a google image search of "site:example.com"

  • 7 - Download Related button

    Click to download this image and all the related images (the ones on the bottom right)

Hotkeys

Global hotkeys

Hotkey Action
O O Enable display original images
s s Force disable safe search (using ipv4.google.com)

Panel-specific (hotkeys that work for an image panel when it is open)

Hotkey Action
o Display original images for current panel
UpArrow Go to previous related image
DownArrow Go to next related image
b search by image

Documentation

  • The docs file contains info about the code and any complicated parts.
  • The reverse engineering contains info about how the website works and the main components it contains (based on observations), such as the CSS selectors for the panels and components, where the info is kept in the page, where thumbnails are loaded and where main images are.

Logs

Dec-2019 backend update

Google changed their webpage HTML AGAIN! :( And now the images aren't in .rg_meta, they're hidden somewhere deep in an array, this is called json transpose. And also the CSS selectors for the elements have been changed, they used to make sense but now they're just gibberish.

Notes and observations:

  • so many anchor.href === "https://www.google.com/null" Reason was that 3361: return normalizeUrl(this.getAttribute('href')); href was null, and normalizeUrl was forcing it to be a string.
  • I noticed that when you right-click, you get the correct URL, but when running showImages(), the anchor.href is null.
  • pretty much all the google functions are inside an object called _
  • clicking the images all the time causes issues. Such as unresponsiveness, ruining the panels (all 3)

Development TODO list

  • add button to download ris images
  • fix navbar, add buttons to hide and show
  • navbar move hide/show buttons to be next to eachother
  • navbar fix that invisible thing that blocks everything
  • add hotkey to go to (s)earch or (i)mages
  • add a listener when a panel appears, to get the same image that the imgbox is using, cuz usually it's blocked or sth so we should just use the one on the imgbox
  • bug: sometimes image anchors are not replaced, they stay https://www.google.com/imgres?imgurl=, and then it fails to load and then it uses DDG proxy
  • SO SLOW!!!! Must optimize
  • panels
    • related images don't actually get observed and don't get direct links replaced
    • fix download button (it)
  • there is some null text on the top left corner
  • remove unneeded buttons and hotkeys
  • select image slider isn't selecting the images. none are qualified for some reason.
    • the reason is that the width and height are not in the meta object
  • related images don't have onhoverListeners

Actions that must be taken:

  • image null URLs are turning into "null" strings, this must be stopped. the anchor is having a null href, that's one of the reasons
  • update selectors
    • should put them all in Consts.Selectors
    • navbar
    • image boxes
    • images
  • get image meta info. (This is from the script json transpose)

External Libraries

This script does use several other external libraries and scripts, they will be listed below with links to their sources.

Scripts

Libraries

these are used via UserScript @requires tags

License

Apache License
Version 2.0, January 2004

About

Userscript to Super-charge Google images with rich features, like: download all full-resolution images, replace thumbnails with full-res images, add "view image" and "download" buttons and much more

Resources

License

Stars

Watchers

Forks

Packages