

If your account is Gmail than host address is “”. Now, we’ve made the connection with the host over an SSL encrypted socket.

You, enter email and password for accessing emails. email_user = input('Email: ') email_pass = input('Password: ') Now firs t, we need email_id and password to access emails. Os is a package using which we can manipulate directories of files present on our local desktop.Įmail is a package used to read, write and send emails from your python script.

Imaplib is the package that installs IMAP a standard email protocol that stores email messages on a mail server, but allows the end user to view and manipulate the messages as though they were stored locally on the end user’s computing device(s).īase64 is a package that provides encoding or decoding of binary data to ASCII characters or vice versa. Import imaplib import base64 import os import email
