Due to Google's security policies, accessing your Gmail account from Nextcloud requires additional steps.
If you use two factor authentication, you'll need to generate an app password:
- Visit https://myaccount.google.com/apppasswords from a web browser
- At the bottom of the page, click the drop-down box labeled "Select app"
- Choose the option, "Other (Custom name)"
- Enter a descriptive name, such as "Nextcloud Mail"
- Click "Generate"
- Go back to Nextcloud (Mail/Rainloop), and enter your e-mail address and the app password you just generated
- Your Gmail account should now be accessible from within Nextcloud
If you are not using two factor authentication, you'll need to allow "Less Secure Apps":
- Visit https://myaccount.google.com/lesssecureapps
- Toggle the radio button "Allow less secure apps" to the "ON" position
- Go back to Nextcloud (Mail/Rainloop), and enter your e-mail address and Google password
- Your Gmail account should now be accessible from within Nextcloud