Hello,
Thanks for contacting us and sorry for any inconvenience that might have been caused due to that.
This error appears when you try to upload a file type that is not supported by WordPress. Please follow this guide to fix the issue: https://rankmath.com/kb/sorry-this-file-type-is-not-permitted-for-security-reasons/#num-2-allow-new-file-types-with-the-file-upload-types-plugin
Hope this helps.
Please don’t hesitate to get in touch in case you need any other assistance.
Same error when uploading the Rankmath Settings.
The file is a .txt file. It is the file that I exported from my other site.
Your above solution is to allow a new file type but not for .txt files. Those are basic ones.
I tried to import by disabling all plugins still the same error.
When I upload .txt file to import settings files of other plugins like Perfmatters or WpRocket it is working.
Hello,
The same error occurs while uploading the .txt
file type, as this is not one of the default file types accepted by WordPress.
You can make use of a plugin called File Upload Types and easily fix the “Sorry, this file type is not permitted for security reasons” error by adding your supported file type.
Please let us know how that goes. Looking forward to helping you further.
Thank you
Please read my reply
“When I upload .txt file to import settings files of other plugins like Perfmatters or WpRocket it is working.”
.txt file from every other plugin like perfmatters, wprocket, generatepress, can be uploaded. only the rankmath one is showing error.
I also uploaded a simple txt file via media library and it is uploaded.
Hello,
To enable unrestricted upload of file types on WordPress, please add the following code to your wp-config
file.
/**The option to upload unrestricted files to WordPress */
define( 'ALLOW_UNFILTERED_UPLOADS', true );
Please let us know how that goes. Looking forward to helping you further.
Thank you
Hello,
Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.
If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.
Thank you.