Export and import putty and WinSCP configuration from Registry

Estimated reading time of this article: 0 minutes 28 seconds

How to easily migrate configured connections in putty and WinSCP?

Export Putty and WinSCP Sessions from Windows Registry

@REM Export Putty and WinSCP Sessions from Windows Registry
@REM 18.10.2016

@SET PREFIX=
reg export "HKCU\Software\SimonTatham\PuTTY\Sessions" "%PREFIX%PuttySessions.reg"
reg export "HKCU\Software\SimonTatham\PuTTY" "%PREFIX%Putty.reg"

@REM https://winscp.net/eng/docs/config#registry_key
reg export "HKCU\Software\Martin Prikryl\WinSCP 2\Sessions" "%PREFIX%WinSCPSessions.reg"
reg export "HKCU\Software\Martin Prikryl\WinSCP 2" "%PREFIX%WinSCP.reg"

Import Putty and WinSCP Sessions into Windows Registry

@REM Import Putty and WinSCP Sessions into Windows Registry
@REM 18.10.2016

@SET PREFIX=
reg import "%PREFIX%PuttySessions.reg"
@REM reg import "HKCU\Software\SimonTatham\PuTTY" "%PREFIX%Putty.reg"

@REM https://winscp.net/eng/docs/config#registry_key
reg import "%PREFIX%WinSCPSessions.reg"
@REM reg import "HKCU\Software\Martin Prikryl\WinSCP 2" "%PREFIX%WinSCP.reg"