Prerequisite: You should have a Google account and thunderbird installed on your machine. Download thunderbird on https://www.thunderbird.net/en-US/.
Converting all Gmail mails to .eml format
Step 1: Open thunderbird and login your Gmail.
Step 2: On the upper right, click the three small horizontal line and select Add-ons and themes.
Step 3: Search for Import Export Tool NG. It will open another tab, Select the Import Export Tool NG and then click Add to Thunderbird
Step 4: After clicking “add to Thunderbird, it will open a pop up message. Click Add.
Step 5: Go back to Inbox tab, right-click inbox, Select ImportExportTools NG, select Export all messages in the folder, and select EML format.
Step 6: Select a folder where you want to save the exported mails. It will take time depending on how many mails do you have.