A browser extension that brings Vim-style keyboard shortcuts to Google Docs, allowing you to edit documents with familiar Vim motions and commands.
While this extension currently implements core Vim functionality including basic motions, text manipulation, and visual selections, there's room for expansion. Contributions are welcome to add more Vim features as per your need.
If you are using DocsKeys with Vimium, disable Vimium on Google Docs.
This project is heavily inspired by and uses much of code from SheetKeys
h- Move cursor leftj- Move cursor downk- Move cursor upl- Move cursor rightw- Move to start of next wordb- Move to start of previous worde- Move to end of current word
{n}h- Move cursor left n times{n}j- Move cursor down n times{n}k- Move cursor up n times{n}l- Move cursor right n times{n}w- Move to start of n words{n}b- Move to start of n previous word{n}e- Move to end of n word
0or^or_- Go to start of line$- Go to end of lineI- Go to start of line and enter insert modeA- Go to end of line and enter insert mode
g- Go to document startG- Go to document end{- Go to start of paragraph}- Go to end of paragraph/- Opens Find & Replace Dialog
i- Enter insert modea- Enter insert mode (after cursor)v- Enter visual modeV- Enter visual line modeEsc- Return to normal modeCtrl+o- Temporary normal mode from insert mode
d+ motion - Delete (supportsdw,diw,dp,dip,dd,d_,d0,d$)c+ motion - Change (supportscw,ciw,cp,cip,cc,c^)y+ motion - Yank/copy (supportsyw,yiw,yp,yip,yy,y0)p- Pasteu- Undor- Redox- Delete character in front of cursor
o- Add new line below and enter insert modeO- Add new line above and enter insert mode
When in visual mode (v or V):
- All movement keys (
h,j,k,l,w,b, etc.) extend the selection d- Delete selected textc- Change selected texty- Yank selected textp- Paste over selected text
Chrome Web Store | Firefox Add-ons
Install from source
- Check out this repository
- Navigate to chrome://extensions in Chrome
- Toggle into Developer Mode
- Click on "Load Unpacked Extension..."
- Select the docskeys folder
- Open a Google Doc
- Extension will automatically activate
- Start using Vim commands in normal mode
- Press
iorato enter insert mode for regular typing - Press
Escto return to normal mode
- Most advanced Vim features like marks, macros, and registers are not supported
- Custom key mappings are not supported
- PR's are welcome to add these features
See MIT-LICENSE.txt for details.