I can reproduce your issue, When I "Export to Excel" a custom list, I get the following notification:"data connections have been blocked. if you choose to enable......"
Choose Enable, it will open the excel.
If you don't want to see the notification, change external content settings for Excel in the Trust Center:
In Excel, click the File tab > Click Options > Trust Center > Trust Center Settings, and then click External Content > choose the option "Enable all Data Connections (not recommended)" under Security settings for Data Connections:
For more detailed information, refer to the following article: