Open In App

HTTP headers | Allow

Improve
Improve
Like Article
Like
Save
Share
Report

The HTTP Allow header is an Entity-type header that specifies the valid methods that are supported by a resource. It is used in response for a 405 Method not allowed. If this header is empty it means the resource does not allow any request methods.

Syntax:

Allow: <http-methods>

Directives: The HTTP Allow header accepts a single directive mentioned above and described below:

  • <http-methods>: This directive holds the list of HTTP request methods. If the requests are more than one then the request are separated by commas.

Examples:

  • When there is just one method. The POST method is used to submit an entity to the specified resource which often causes a change in state on the server.
    Allow: POST
  • When there are multiple methods. The PATCH method is used to apply partial modifications to a resource while the DELETE method deletes the specified resource.
    Allow: PATCH, DELETE

To check this Allow in action go to Inspect Element -> Network check the header for Allow like below.

Supported browsers: The browsers compatible with HTTP Allow header are listed below:

  • Google Chrome
  • Internet Explorer
  • Firefox
  • Safari
  • Opera

Last Updated : 19 Nov, 2019
Like Article
Save Article
Previous
Next
Share your thoughts in the comments
Similar Reads