It might be better to re-download them if they sit on a IMAP server than trying to import them from TimeMachine.
Phase 1: Locate and Restore the Files
Quit Mail: Ensure the Mail app is completely closed.
Open Finder: In the top menu bar, select Go > Go to Folder...
Enter the path: Type ~/Library/Mail and press Enter.
Enter Time Machine: Click the Time Machine icon in your menu bar and select Enter Time Machine.
Navigate back in time: Use the timeline on the right to find the date you want to restore from.
Find the "V" folder: Look for a folder named with a "V" followed by a number (e.g., V10 for Ventura/Sonoma or V13 for newer OS versions).
Restore to Desktop: Right-click the folder (or specific account folders within it) and select Restore [Folder Name] to.... Choose your Desktop as the destination.
- Note: Do not restore it directly to its original location, as this can overwrite your current emails.
Phase 2: Import into Apple Mail
Once the files are on your Desktop, follow these steps to bring them into your current Mail app:
Open Mail.
Import: Go to File > Import Mailboxes...
Choose Source: Select Apple Mail and click Continue.
Select the Restored Folder: Navigate to the folder you restored to your Desktop. Drill down into it until you see folders with long alphanumeric names (these represent your accounts). Choose the folder containing the specific mailboxes you need.
Complete Import: Mail will create a new section in your sidebar called "Import"
Phase 3: Organize Your Emails
Your old emails will now appear in the Import mailbox in the sidebar.
You can now drag and drop these messages or folders into your active Inbox or "On My Mac" folders.
Once you've moved everything you need, you can right-click the "Import" mailbox and delete it to clean up your sidebar.
Troubleshooting Tips
Missing Folders? If you can't see the ~/Library folder, it’s hidden by default. In Finder, hold the Option key while clicking the Go menu to make it appear.
.partial.emlx files: If you see files ending in .partial.emlx, these are sometimes "ghost" files that didn't fully download. Usually, importing the parent folder as "Apple Mail" fixes this, but you may need to re-index your mailboxes (Mail > Mailbox > Rebuild) if they look blank after importing.
This answer was found on Gemini.