Where to find your password
  1. Ensure 2-Step Verification is enabled on your Google Account—otherwise app passwords aren’t available.
  2. Go to the Security section of your Google Account (e.g. myaccount.google.com/security).
  3. Under “Signing in to Google,” click App Passwords or follow the direct URL
  4. Sign in again if prompted to verify identity.
  5. Choose the app (e.g. Mail) and device (or select Other (Custom name) to type your own).
  6. Click Generate, then copy the 16‑character app password.
  7. Use the app password instead of your regular account password when signing in from a third‑party app (e.g. IMAP/SMTP client).
  8. Click Done. App passwords are automatically revoked if you change your main account password.
More info: Google’s official “Sign in with app passwords” help page
IMAP Settings
SMTP Settings