Home > 307

How to fix error 307?

Alton Alexander
By Alton AlexanderUpdated on June 3rd, 2022

The HTTP status code 307 is a temporary redirect, meaning that the requested resource is available elsewhere but the original URL should still be used. This can happen when a website's DNS changes or when a page is moved to a new server. This error code is often seen when a user tries to access a website that is no longer available.

Users typically search for a solution by asking about:

  • error code 307
  • 307

1. Add a Content-Length header to your request

In order to add a Content-Length header to your request in order to fix 307 response, the following steps must be followed:

  1. In your web browser, navigate to the URL of the page or document you would like to request.
  2. In the address bar, type "http://www.example.com/page.html" and press Enter.
  3. In the HTTP response header section of the web browser, locate and click on the "Content-Length" header.
  4. In the "Content-Length" header field, type the value you would like to assign to the request's Content-Length header.
  5. Click on the "OK" button to save your changes and close the HTTP response header section of the web browser.

2. Add a Transfer-Encoding header to your request

  1. In your HTTP request, add the "Transfer-Encoding" header with the value "chunked"
  2. In the response, the server will return a 307 response with the Content-Length header set to the number of bytes in the chunked transfer encoding
  3. Check the Content-Length header to make sure it is set to a value larger than the size of the data in the chunked transfer encoding
  4. If the Content-Length header is not set, the data in the chunked transfer encoding may not have been compressed, and the server may not be able to process it
  5. If the Content-Length header is set to a value smaller than the size of the data in the chunked transfer encoding, the server may not be able to process the data due to an invalid encoding

3. Use a different HTTP method

  1. Create a new HTTP method in the Application Configuration file.
  2. Update the URL in the Application Configuration file to use the new HTTP method.
  3. Restart the Application.

4. Use a different URI

To use a different URI in order to fix 307 redirects:

  1. Navigate to the desired page on the web server.
  2. Copy the desired URI into the address bar of your web browser.
  3. Press Enter.
  4. The web browser should redirect you to the new URI.
  5. Enjoy your new URI!

5. Use a different HTTP version

  1. open your browser and type in "http://www.site.com"
  2. If you see the website you're looking for, congrats! If not, try changing your HTTP version to see if that resolves the issue.
  3. To change your HTTP version, you'll first need to know your browser's "HTTP Versions" setting. For Chrome, Firefox, and Safari, it's usually located in the "Tools" menu. For Internet Explorer, it's usually located in the "Internet Options" menu.
  4. Once you've located the HTTP Versions setting, click on it.
  5. On the HTTP Versions page, you'll see a list of available versions. You can select the version you want to use by clicking on it.
  6. After you've selected the version, click on the "Apply" button.
  7. If the issue still persists, try using a different web browser. If that doesn't work, you'll need to contact your hosting provider to ask for help resolving the issue.

If you didn't find success with an option above, then try:

  1. Use a different client