Problem with Gmail IMAP closed connection

Error in gmail that says IMAP server has closed connection.  The port configuration is 993.
Tools / Email Accounts / (your
account) / Change / More Settings / Advanced / Server Timeouts
Change this to 5 minutes

Gmail not working with IMAP

Are you able to send email through Outlook but you are stuck on a status message that says, “Checking for new mail in subscribed folders on”? If so you need to check your firewall and make sure outbound port 993 and 465 are open.