Bobcares

DELETE, PUT, and PATCH verbs are not allowed on Plesk for Windows

PDF Header PDF Footer

Learn what to do if the DELETE, PUT, and PATCH verbs are not allowed on Plesk for Windows. Our Plesk Support team is here to help you with your questions and concerns.

DELETE, PUT, and PATCH verbs are not allowed on Plesk for Windows

DELETE, PUT, and PATCH verbs are not allowed on Plesk for WindowsIf you are working with PHP files or Web APIs on a Plesk server, you may have run into the following error when using certain HTTP methods like `DELETE`, `PUT`, or `PATCH`:

405 – HTTP verb used to access this page is not allowed
The page you are looking for cannot be displayed because an invalid method (HTTP verb) was used to attempt access.

Today, we will examine closely why this error occurs and how to resolve it using IIS Manager and Plesk.

Why This Error Occurs

According to our Experts, this error is usually caused by a misconfiguration in IIS Handler Mappings. For instance, our HTTP method is not registered for the file type or handler associated with the application. A frequent cause is the WebDAV module, which often conflicts with handlers like PHP or .NET Core.

If you’re also managing Windows licensing and encountering issues, this guide on activating Windows via command line might be helpful alongside your server setup.

How to Solve the “405 – HTTP Verb Not Allowed” Error

  1. First, connect to the Plesk server via Remote Desktop (RDP).
  2. Then, go to Start > All Programs > Windows Administrative Tools and launch Internet Information Services (IIS) Manager.
  3. Now, expand the server node in IIS Manager.
  4. Then, go to Sites > example.com.
  5. Next, click Handler Mappings under the IIS section and find the handler associated with our application and double-click on it,
  6. At this point, click Request Restrictions and go to the Verbs tab.
  7. In the “One of the following verbs” box, enter:
    GET,HEAD,POST,PUT,DELETE,PATCH
  8. Then, click OK to save the changes.
  9. However, if you get an error like this:

    “The specified executable for the handler must be a .dll or .exe file.

    It means the path in the Executable (optional) field contains spaces. To fix it, wrap the path in double quotes.

    For example:

    “C:\Program Files (x86)\Plesk\Additional\PleskPHP74\php-cgi.exe”|-d siteId=10
  10. It is time to remove the WebDAV Module from web.config. WebDAV can block non-standard HTTP methods. There are two ways to get this done:
    • Via IIS (Optional)

      We can add the following directly through the web.config or IIS:

      <system.webServer>
      <modules>
      <remove name="WebDAVModule" />
      </modules>
      <handlers>
      <remove name="WebDAV" />
      </handlers>
      </system.webServer>
    • Via Plesk File Manager
      1. Log in to Plesk.
      2. Then, go to Domains > example.com > File Manager.
      3. Open the `web.config` file. Before editing it, it’s always a good idea to create a backup in case anything goes wrong.
      4. Locate the <system.webServer> section.
      5. Add the following inside it:
        <modules>
        <remove name="WebDAVModule" />
        </modules>
        <handlers>
        <remove name="WebDAV" />
        </handlers>

        If the <modules> or <handlers> section already exists, insert the <remove> lines within the respective blocks.

      6. Save the file and exit.

Working with virtual environments? Our guide on booting Windows from a physical disk in KVM might be relevant if you manage Windows-based VMs in parallel.

After saving your changes, restart the IIS site or refresh the application. Then, try again using the `DELETE`, `PUT`, or `PATCH` methods to confirm that the issue is resolved.

 

Encountering strange Windows errors like 0x80004005? Learn how to fix the 0x80004005 error in Windows 11 for a smoother troubleshooting experience.

[Need assistance with a different issue? Our team is available 24/7.]

Conclusion

The “405 – HTTP verb not allowed” error is usually caused by restrictive handler configurations or conflicts with the WebDAV module. By updating the handler settings and modifying the web.config file, we can enable full support for modern HTTP methods in the PHP or Web API applications hosted on Plesk.

In brief, our Support Experts demonstrated what to do if DELETE, PUT, and PATCH verbs are not allowed on Plesk for Windows.

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

GET UP TO 25% OFF

Plesk Support

Spend time on your business, not on your servers.

Managing a server is time consuming. Whether you are an expert or a newbie, that is time you could use to focus on your product or service. Leave your server management & end-user tech support to us, and use that time to focus on the growth and success of your business.

TALK TO USOr click here to learn more.

Speed issues driving customers away?
We’ve got your back!

Privacy Preference Center

Necessary

Necessary cookies help make a website usable by enabling basic functions like page navigation and access to secure areas of the website. The website cannot function properly without these cookies.

PHPSESSID - Preserves user session state across page requests.

gdpr[consent_types] - Used to store user consents.

gdpr[allowed_cookies] - Used to store user allowed cookies.

PHPSESSID, gdpr[consent_types], gdpr[allowed_cookies]
PHPSESSID
WHMCSpKDlPzh2chML

Statistics

Statistic cookies help website owners to understand how visitors interact with websites by collecting and reporting information anonymously.

_ga - Preserves user session state across page requests.

_gat - Used by Google Analytics to throttle request rate

_gid - Registers a unique ID that is used to generate statistical data on how you use the website.

smartlookCookie - Used to collect user device and location information of the site visitors to improve the websites User Experience.

_ga, _gat, _gid
_ga, _gat, _gid
smartlookCookie
_clck, _clsk, CLID, ANONCHK, MR, MUID, SM

Marketing

Marketing cookies are used to track visitors across websites. The intention is to display ads that are relevant and engaging for the individual user and thereby more valuable for publishers and third party advertisers.

IDE - Used by Google DoubleClick to register and report the website user's actions after viewing or clicking one of the advertiser's ads with the purpose of measuring the efficacy of an ad and to present targeted ads to the user.

test_cookie - Used to check if the user's browser supports cookies.

1P_JAR - Google cookie. These cookies are used to collect website statistics and track conversion rates.

NID - Registers a unique ID that identifies a returning user's device. The ID is used for serving ads that are most relevant to the user.

DV - Google ad personalisation

_reb2bgeo - The visitor's geographical location

_reb2bloaded - Whether or not the script loaded for the visitor

_reb2bref - The referring URL for the visit

_reb2bsessionID - The visitor's RB2B session ID

_reb2buid - The visitor's RB2B user ID

IDE, test_cookie, 1P_JAR, NID, DV, NID
IDE, test_cookie
1P_JAR, NID, DV
NID
hblid
_reb2bgeo, _reb2bloaded, _reb2bref, _reb2bsessionID, _reb2buid

Security

These are essential site cookies, used by the google reCAPTCHA. These cookies use an unique identifier to verify if a visitor is human or a bot.

SID, APISID, HSID, NID, PREF
SID, APISID, HSID, NID, PREF