This post is mostly meant as a reminder for myself. When adding an email account that had long been in use to Thunderbird, I wanted to have a complete local copy of all mails from all folders. But I did not want to subscribe to hundreds of folders manually and then click each of them to trigger the download.
Luckily, there is an “extended setting” that achieves exactly what I need. You need to go the “normal” settings (not the account ones) and there to the “Advanced” tab. At the bottom there is the “Config Editor” button, which you need to click and confirm the warning.
Then set the property
mail.server.default.check_all_folders_for_new = true
and close the windows.
After a few seconds Thunderbird will start downloading the entire tree of folders from your account.