---
title: File Type Not Permitted when Uploading Media
url: "https://pressable.com/knowledgebase/file-type-not-permitted-when-uploading-media/"
published: 2023-05-25
modified: 2024-08-19
author: Wayne McWilliams
---

If you are uploading files in the media library or within form elements on your WordPress site and receive this error:

*`<strong>Sorry, this file type is not permitted for security reasons.</strong>`*

The way to resolve this it to edit the wp-config.php file and copy/paste the below code snippet above the `/* That’s all, stop editing! */` line:

```
define('ALLOW_UNFILTERED_UPLOADS', true);
```

Another option is the [WP Extra File Types](https://wordpress.org/plugins/wp-extra-file-types/) plugin, which allows you to control which file types can be uploaded.
