I am using gmail via the mail app on my Mac computers and iOS devices and cannot figure out how to set-up so that when I delete an email it is deleted from all devices and gmail server (trashed and not archived). I don't actually use the mail app on my computers but need to import my gmail account to set-up mail. I'll find that some email deleted from my iPad or iPhone will still be visible when I use gmail on my computers, and much of this mail is also under 'all mail' and archived rather than in my trash that auto deleted after 30 days. If I delete something I want it in the trash, not archived unless I specify that option, but have been unable to figure out how to change this? Hope someone knows the answer as I have tons of archived mail in my gmail account that I'd like to get rid of permanently since many are ads, etc.
How to customize gmail settings when set up with IMAP via Apple Mail
General Apple News & DiscussionTo set to delete mail on your phone, go to settings > mail > Accounts > gmail> Account > advanced > check "deleted mailbox". Return to Account > Tap Done in the upper right corner.
Thanks for the reply and 'think' I have those settings enabled but I'll re-check on both my iPhone and iPad. The issue might be more of a Gmail setting for email behavior with IMAP accounts because there are some settings to choose from under the IMAP section? It may possibly only affect the email that I delete when using my computers since I don't use the Apple mail app and access Gmail directly when using my iMac or MacBook. Thoughts on this?
If you want your Gmail to act independent on your devices, you might have to set it up on the phone as a pop account, rather than imap. Not sure of that though. I simply set mine as as it does it on my phone. Entered my credentials and it was done.
The default is to archive, but use the settings @Ledsteplin showed and you'll be deleting in no time.
Thanks, I'll try these settings as I had the same question.
Be sure after you check "deleted mailbox", you return to the "account" page and tap "Done" in the upper right corner.
Thanks!
I mention that because when I first set up mine, I missed it. It was later someone showed me my error.

It's easy to miss, thanks again.
Original thread: https://forums.imore.com/threads/how-to-customize-gmail-settings-when-set-up-with-imap-via-apple-mail.384982/