Google Sheets Script. Range 2 Image
Hi, this is Max from Cooltables!
Here’s the demo:
🙌 The latest version of the script goes with the Cooltables add-on. Here is how to capture range screenshots without code:
Cooltables
The Range to Image feature inside Cooltables:
- ⚡ 10x faster, especially for larger ranges.
- 📐 Images are precisely cropped — no unwanted white space.
- 🔍 Smarter scaling to handle even bigger spreadsheet captures.
- 🖥️ Larger preview area to view images clearly.
Cooltables also includes additional handy tools you’ll discover and appreciate.
How to get started:
- Open any Google Sheet.
- Go to Extensions → Add-ons → Get add-ons.
- Search Cooltables and click Install.
✅ To convert a range to an image:
Just select your range, then click:
Extensions → Cooltables → Tools → Convert Selected Range to Image
The script converts the selected range to a high-resolution image.
How it works
It creates an URL for PDF first and then uses Canvas and Pdf.js to convert it into PNG.
Instruction:
- Select a range
- Use the custom menu to launch the script. Authorize and rerun it when you do it the first time.
- Wait until the image is rendered.
- Optionally right-click the image and save/copy it to your computer.
Issues
We want to solve this issue:
- We cannot capture emojis, bug by Google. If you are interested in fixing it, please vote here.
Benefits
We recommend using the script if:
- You need to create a screenshot and use it later: send it to Telegram or email or use it in Slides.
- You want to create an image of cells as you see them on screen, containing images, charts, sparklines, etc.
- You want to create a screenshot of a range that does not fit your screen.
- You want to create a screenshot of a range with high resolution.
The code
The script is still under construction. You’re welcome to join our tests: