Anki add-on for importing cards from Google Sheets
Google Sheets Syncer - goosheesy
Anki add-on for importing cards from spreadsheet tables on Google Sheets.
Add-on page on AnkiWeb: https://ankiweb.net/shared/info/258119705
It's best suited and tested on importing the translation pairs in form "word-translation".
Installation
- To install the add-on version published on AnkiWeb: launch Anki, select
Tools->Add-ons->Get Add-ons... and enter the add-on ID 258119705.
- To install manually from the
.ankiaddon package, download the package from GitHub releases page, and select in Anki Tools->Add-ons->Install from file.
Usage Flow
Create decks_import_config.json file which maps your Google Sheets to Anki decks, for example:
{
"synchronization_map":[
{
"spreadsheet_name":"My Japanese Vocabulary spreadsheet",
"sheets":[
{
"sheet_name":"Japanese Google Sheet",
"deck_name":"Japanese Anki deck"
},
{
"sheet_name":"My second sheet",
"deck_name":"My second deck"
}
]
}
]
}
On Google Sheets create a spreadsheet called "My Japanese Vocabulary spreadsheet", create there a sheet called "Japanese Google Sheet" and put words for "Front" flashcard side to column "A", and put translations for "Back" flashcard side to column "B". Create
Each sheet in the spreadsheet is one-way synchronized into the Anki deck.
Cards are updated based on the following logic:
- Card is present in Google Sheets but absent in Anki deck -> a card is created in Anki deck.
- Card is present in Anki deck but absent in Google Sheets -> the card is deleted from Anki deck.
- Card is present both in Anki and Google Sheets -> card value is updated if necessary.
Use add-on in Anki:
-
Launch Anki.
-
Press Tools->Settings for Google Sheets import.
-
Press Tools->Import from Google Sheets. If everything is configured correctly during previous steps, the window will look like following:

Development
Anki add-on development has some nuances.
To prepare the project for development:
- Clone the repo.
- In order for Anki to download the add-on from the source code of repository, create a symlink:
- Install third-party dependencies (for runtime) for Windows:
python -m pip install -r requirements.txt -t ./vendor/win_amd64 --only-binary=:all:
- Install third-party dependencies (for runtime) for Linux:
python -m pip install `
--platform manylinux_2_28_x86_64 `
--python-version 3.13 `
--implementation cp `
--abi cp313 `
--only-binary=:all: `
--target ./vendor/linux_amd64 `
-r requirements.txt
- Install third-party dependencies for development:
python -m pip install -r requirements_dev.txt -t ./addon_packages_dev
- Print package version to add new dependency to requirements.txt:
pip show PACKAGE_NAME
Debugging
In __init__.py, set WAIT_FOR_DEBUGGER_ATTACHED variable to True.
To debug, launch Anki first. It will freeze and won't launch until you hit F5 in VSCode and attach the debugger to the add-on.
Deployment
- Ensure the third-party dependency modules are installed to the 'vendor' directory.
- Increase version number in
version.txt file.
- Update CHANGELOG.md file.
- Create add-on package archive by running the
package_addon script.
- Upload to https://ankiweb.net/shared/addons.
- Upload to releases page on GitHub.
Useful links
- https://addon-docs.ankiweb.net/intro.html
- https://ankiweb.net/shared/addons
- https://github.com/ankidroid/Anki-Android/wiki/Database-Structure
- Anki Python API: https://addon-docs.ankiweb.net/the-anki-module.html
- Python modules: https://addon-docs.ankiweb.net/python-modules.html
Notes
- Import of several sheets into the same deck is not supported at the moment.
License
Licensed under the MIT license. Distribution is free, copyright notice is required.