A powerful Tampermonkey/Greasemonkey script designed to enhance the quality of life and functionality within the Google AI Studio interface. It adds advanced navigation, library organization, detailed metadata, and customization options.
The library view is completely transformed to provide more data at a glance.
- New Columns: Adds "Created" (Date), "Count" (Messages), and "Tokens" (Total context).
- Visual Grouping: Automatically detects "Branch of" and "Copy of" relationships, visually indenting them under their parent chat for a clean file tree structure.
- Sorting: All new columns are sortable.
Never lose track of your conversation branches again.
- Family Tree: The top toolbar displays numbered links to the Parent, Siblings, and Children of the current chat.
- Smart Coloring: Links turn Green if that branch is newer than the one you are currently viewing.
- Session Info: Displays the exact creation date and a relative "Last Modified" timer right next to the token count.
Navigate long context windows with ease using dedicated tools injected into the UI.
- Find in Chat: A custom search bar (accessible via the 3-dot menu) allows you to search specifically within the chat message content, highlighting results and jumping between them.
- Dual Scroll Buttons: Floating Action Buttons (FABs) in the bottom right allow you to jump precisely to the Previous or Next message turn, skipping over long blocks of text.
| Find in Chat | Scroll Navigator |
|---|---|
![]() |
![]() |
A new "Enhancer" button in the Settings menu opens a dedicated configuration modal.
- Appearance: Customize date formats (Short, American, Relative) and the color of the Token count in the library.
- Force Sync: A dedicated button to force a synchronization with Google Drive, useful for cleaning up "ghost" chats or updating metadata immediately.
To reduce clutter, native buttons like "Share", "Compare", and "New Chat" are moved into the "More Actions" (3-dot) menu.
- Export Options: Adds one-click options to export your full chat history to JSON or Markdown.
The script requires Google Drive API access to fetch creation and modification dates for your conversations. You need to generate a "Refresh Token" so the script can stay logged in.
- Go to the Google Cloud Console.
- Create a new project (e.g., named "AI Studio Enhancer").
- Enable the Drive API:
- Go to APIs & Services > Library.
- Search for "Google Drive API" and click Enable.
- Create Credentials:
- Go to APIs & Services > Credentials.
- Click Create Credentials > OAuth 2.0 Client ID.
- (If prompted, configure the Consent Screen: Select "External", give it a name, and save).
- Application Type: Select Desktop app.
- Click Create.
We have provided a script that automates the process.
- Download JSON: In the Google Cloud Console (where you created credentials in Step 1), click the Download JSON button for your OAuth Client.
- Save File: Save the file into the same folder as this repo.
- Note: The filename will start with
client_secret_...and end in.json.
- Note: The filename will start with
- Install Requirements:
pip install google-auth-oauthlib
- Run Script:
python get_drive_tokens.py
- Follow Prompts: The script will detect your JSON file, give you a URL to visit to authorize, and then output the exact configuration block you need.
If you don't want to run Python, you can do this manually.
- Get ID & Secret: In Google Cloud Console, copy your Client ID and Client Secret.
- Go to the OAuth 2.0 Playground.
- Click the Settings (Gear icon) in the top right.
- Check Use your own OAuth credentials.
- Paste your Client ID and Client Secret.
- Select Scopes:
- In the list on the left, find "Drive API v3".
- Select
https://www.googleapis.com/auth/drive.readonly. - Click Authorize APIs.
- Exchange Tokens:
- Click "Exchange authorization code for tokens".
- Copy the Refresh Token from the response.
Whichever method you used, you now have a Client ID, Client Secret, and Refresh Token.
- Open the
aistudio-plus.user.jsscript in your Tampermonkey/Greasemonkey editor. - Find the
CONFIGblock at the top of the file:
const CONFIG = {
CLIENT_ID: "YOUR_CLIENT_ID",
CLIENT_SECRET: "YOUR_CLIENT_SECRET",
REFRESH_TOKEN: "YOUR_REFRESH_TOKEN",
FOLDER_NAME: "Google AI Studio",
SYNC_INTERVAL_MINUTES: 15
};- Replace the placeholder values with your actual credentials.
- Save and reload AI Studio.
- Install Manager: Get Tampermonkey (Chrome/Edge) or Greasemonkey (Firefox).
- Install Script: Click here to install
aistudio-plus.user.js - Configure: Follow the "Google Credentials Configuration" steps above.
- Enjoy: Reload Google AI Studio.
Developed by Esashiero, with architectural guidance provided by Gemini.
Developed for the Google AI Studio platform.

