I am trying to upload a configuration file so I can include a link to it in my post. And I get a Security error, because the file type is not allowed.

My config file has no extension.

I found this question: Adding file types in wordpress

Is there a way that I can add the mime type of '' for a "No Extension" type?

  • couldn't you just upload it via ftp?
    – NW Tech
    May 20, 2011 at 19:00
  • @Chip Well, I can certainly get the file in the uploads directory (I can simply mv or FTP it there). But I can't figure out how to get it to show in "Media" once it's there, so I can link to it from WP.
    – Howler
    May 20, 2011 at 19:28
  • I have same issue. I want to upload the file (having no format) from front-end but I got the error "Sorry, this file type is not permitted for security reasons.I have tried all solution available on internet, but nothing works. Jul 17, 2020 at 2:15

2 Answers 2


Why not just add .txt to the file? It's probably the safest thing to do. If you need the file name to display without the extension, you can always filter the string.

  • Yeah, this had occurred to me as well, and I suppose is a valid solution. It just adds another step for anyone who would want to download my config "as-is", because they would have to rename it to remove the ".txt"
    – Howler
    May 23, 2011 at 16:12

I'm not able to install plugins atm to test, but maybe this plugin would work for the files you FTP - Add From Server

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.