You cannot move single keys or even keypairs, but you can move the entire keyring:
- Move GnuPG data directory (
~/.gnupg; on Windows %APPDATA%\.gnupg) to your chosen location.
- For extra security, copy and secure-wipe instead of just moving (which does an insecure deletion).
- Set the
GNUPGHOME environment variable to the new location.
- System Properties → Advanced → Environment Variables. Alternatively, in Windows 7, search for "environ" in Control Panel.
- Click Add, enter
GNUPGHOME as name and the new path as value.
- For example,
E:\private\gnupg or C:\mnt\jwir3 flash drive\GnuPG or whatever the hell you moved your keys to.
- The currently running programs will not see your changes. Exception: Windows Shell (
explorer.exe), which receives a change notification. So you need to close Kleopatra and restart it from the Start menu.
EDIT: Looks like it's actually the GNUPGHOME environment variable, rather than GNUPG_HOME