Google Sheets Cell Comment Exporter
Free to download on every platform. Comes pre-installed on BotFone, BotPad and BotFlip — with extra free apps included.
About this app
WHAT IT DOES
This script extracts all comments and threaded discussions from your Google Sheets document and exports them to a downloadable file. When you open a Google Sheet, the script scans the entire sheet for comment indicators, including cell notes, threaded comments, and sidebar discussions. It extracts each comment's cell reference (row and column), author name, comment text, timestamp, and any reply threads. The extracted data is displayed as a list in the settings panel, showing you a quick overview of all comments in the document. You can then export all comments to CSV (for Excel and spreadsheet applications), JSON (for developers and data analysis), or plain text. A "Copy to clipboard" button lets you copy the data without downloading a file. The script updates dynamically as comments are added, edited, or deleted, so your export always reflects the current state of the document.
WHERE IT RUNS
The script runs on all Google Sheets domains (docs.google.com/spreadsheets/). It works on the main sheet editor, the print preview, and the mobile view. It supports both individual sheets and documents with multiple sheets (comments from the active sheet are scanned).
HOW TO USE
After installation, the settings panel appears on the left side of the screen with the gear emoji (⚙️). Open the panel to configure the script:
- The "Enable comment export" toggle enables or disables the script.
- Click "Scan for comments" to manually scan the sheet for comments (the script also scans automatically on page load).
- The comment list displays all found comments with cell references, author names, and previews of the comment text.
- Choose the export format from the dropdown: CSV, JSON, or Plain Text.
- Toggle "Include timestamps" to include or exclude comment timestamps in the export.
- Toggle "Include replies" to include or exclude reply threads.
- Click "Export" to download the comment data as a file.
- Click "Copy to clipboard" to copy the comment data to your clipboard.
The script works automatically—just open your Google Sheet and the comments will be detected.
TECHNICAL SECTION — REAL MECHANISM
The script detects Google Sheets editor pages by checking the URL for /spreadsheets/ and /d/. It finds comment indicators using multiple selectors: .comment-indicator, .cell-comment-indicator, .cell-note-indicator, .comment-marker, [data-comment-id], [data-note-id], and .docs-comment-indicator. It extracts comment data from three primary sources: cell indicators (small triangles or markers on cells that contain comments), the right sidebar comment threads (which contain threaded discussions), and cell data attributes (data-note, data-comment). For each comment, the script extracts the cell reference from parent elements or data-cell attributes, the author name from .comment-author or similar, the comment text from .comment-text or .comment-body, the timestamp from .comment-time, and any reply threads from .comment-reply or .thread-reply. All extracted data is stored in a JavaScript array. The comment list is rendered in the panel using style properties and textContent (never innerHTML). Export functions convert the data to CSV (with proper quoting and escaping), JSON (structured with proper formatting), or plain text (human-readable format). The script uses a MutationObserver to watch for DOM changes and re-scans when new comment indicators appear.
THE PANEL
The settings panel is built with BotGentz's BGPanel component. It is draggable via its header, allowing you to reposition it anywhere on the screen. The panel snaps to the left edge by default but can be moved freely. Click the gear emoji to collapse the panel into a small bubble, and click the bubble to expand it again. The panel remembers its position per page session. Press the Escape key to quickly close or minimize the panel. The panel includes a status flash bar that provides visual feedback when settings are changed or actions are performed. The comment list is displayed directly in the panel for quick reference. All settings save automatically via GM_setValue.
PLEASE NOTE
This script requires the free BotGentz browser extension to run. It does not function as a standalone Chrome extension and does not use chrome.* APIs. Google Sheets frequently updates its interface and comment system, which may break the selectors used to find comments. If comments are not being detected, please check for script updates. The script extracts comments from the active sheet only; comments on other sheets in the same document are not scanned unless you switch to that sheet and refresh. The script stores only your preferences (enabled state, export format, timestamp and reply toggles) via GM_setValue. No data is sent externally—all data is stored and processed locally in your browser. The script never reads or writes password fields, hidden inputs, or file inputs. All DOM operations use safe methods (style properties, textContent, appendChild) and never use innerHTML.