A browser script that adds keyboard shortcuts to quickly create new chats in Google's Gemini AI interface, similar to how Ctrl+M creates new slides in Google Slides.
This script adds platform-specific keyboard shortcuts to Gemini that instantly create a new chat:
- macOS:
Ctrl+M
orCtrl+N
- Windows/Linux:
Ctrl+M
orCtrl+Shift+N
No more clicking around - just press the hotkey and start a fresh conversation with Gemini!
The main script is located at: src/script.js
Arc Browser has built-in support for custom scripts through Boosts:
- Open Gemini in Arc Browser (
gemini.google.com
) - Create a new boost using either method:
- Press
Cmd + T
and select "New Boost" - Click the dustpan icon in the Site Control Center
- Press
- Choose "Code {}" followed by JS
- Copy the script from
src/script.js
- Paste it into the boost editor
- Save the boost
- The script will now run automatically whenever you visit Gemini!
Use a userscript manager like Violentmonkey:
- Chrome: Install from Chrome Web Store
- Edge: Install from Edge Add-ons
- Firefox: Install from Firefox Add-ons
- Click the Violentmonkey extension icon
- Select "Create a new script"
- Replace the default template with this:
// ==UserScript==
// @name Gemini New Chat Hotkey
// @namespace https://github.com/your-username/gemini-ctrl-n
// @match https://gemini.google.com/*
// @grant none
// @version 1.0
// @author Conrad Koh
// @description Add keyboard shortcuts (Ctrl+M, Ctrl+N/Ctrl+Shift+N) for creating new chats in Gemini AI
// @homepage https://github.com/your-username/gemini-ctrl-n
// @supportURL https://github.com/your-username/gemini-ctrl-n/issues
// @license MIT
// ==/UserScript==
// Paste the contents of src/script.js here
- Copy the entire contents of
src/script.js
- Paste it after the userscript header (replacing the comment)
- Save the script (Ctrl+S)
- Refresh your Gemini tab
- Press your platform's hotkey to test:
- macOS:
Ctrl+M
orCtrl+N
- Windows/Linux:
Ctrl+M
orCtrl+Shift+N
- macOS:
Platform | Hotkeys | Description |
---|---|---|
macOS | Ctrl+M |
Google Slides style (universal) |
macOS | Ctrl+N |
macOS-specific new chat |
Windows/Linux | Ctrl+M |
Google Slides style (universal) |
Windows/Linux | Ctrl+Shift+N |
Windows convention |
- Open browser console (F12 → Console tab)
- Look for initialization messages like:
Gemini new chat hotkey script loaded Platform detected: macOS Gemini new chat hotkey script initialized.
Run this in the console to debug:
debugGeminiNewChat();
This will show all potential new chat buttons on the page and test each selector.
Run this in the console:
showGeminiHotkeys();
Want to modify the hotkeys? Edit the HOTKEY_CONFIG
object in src/script.js
:
const HOTKEY_CONFIG = {
mac: [
{
keys: { ctrl: true, key: "m" },
name: "Ctrl+M",
description: "Google Slides style",
},
// Add your custom hotkey here
],
windows: [
{
keys: { ctrl: true, key: "m" },
name: "Ctrl+M",
description: "Google Slides style",
},
// Add your custom hotkey here
],
};
- Platform Detection: Automatically detects if you're on macOS or Windows/Linux
- Event Listening: Monitors keyboard events for the configured hotkeys
- Button Finding: Searches for the new chat button using multiple selectors
- Click Simulation: Programmatically clicks the button when hotkey is pressed
Found a bug or want to improve the script? Feel free to:
- Open an issue
- Submit a pull request
- Suggest new features
This project is open source and available under the MIT License.
Enjoy faster Gemini conversations! 🚀