Error Codes Wiki

HTTP 307 Temporary Redirect — What It Means & How to Fix It

Warning3xx redirection

About HTTP 307 Temporary Redirect

The HTTP 307 Temporary Redirect status code indicates the resource is temporarily at a different URL, and the client must use the same HTTP method for the redirect request. This guide covers everything you need to know about this topic, including common causes, step-by-step solutions, and answers to frequently asked questions.

Here are the key things to understand: Unlike 302, this status code guarantees the HTTP method will not change during the redirect.. A POST request will remain a POST after following the redirect.. The client should continue using the original URL for future requests.. It was introduced in HTTP/1.1 to fix the ambiguity of 302 regarding method preservation.. Understanding these fundamentals will help you diagnose and resolve this issue more effectively.

The most common reasons this occurs include: A resource is temporarily available at a different location.. HTTPS enforcement redirecting HTTP to HTTPS while preserving the method.. Load balancing or failover directing traffic to a backup server.. Identifying the root cause is the first step toward finding the right solution.

To resolve this, follow these recommended steps: Follow the redirect to the URL in the Location header using the same HTTP method.. Resend the original request body if applicable.. Continue using the original URL for future requests.. Verify the redirect preserves your intended HTTP method.. If these steps do not resolve the issue, consider consulting additional resources or a qualified professional.

This article is part of our HTTP Status Codes collection on Error Codes Wiki. We provide comprehensive, up-to-date information to help you find solutions quickly.

Quick Answer

What does HTTP 307 mean?

It means the resource is temporarily at another URL and the client must use the exact same HTTP method for the redirected request.

Overview

The HTTP 307 Temporary Redirect status code indicates the resource is temporarily at a different URL, and the client must use the same HTTP method for the redirect request.

Key Details

  • Unlike 302, this status code guarantees the HTTP method will not change during the redirect.
  • A POST request will remain a POST after following the redirect.
  • The client should continue using the original URL for future requests.
  • It was introduced in HTTP/1.1 to fix the ambiguity of 302 regarding method preservation.

Common Causes

  • A resource is temporarily available at a different location.
  • HTTPS enforcement redirecting HTTP to HTTPS while preserving the method.
  • Load balancing or failover directing traffic to a backup server.

Steps

  1. 1Follow the redirect to the URL in the Location header using the same HTTP method.
  2. 2Resend the original request body if applicable.
  3. 3Continue using the original URL for future requests.
  4. 4Verify the redirect preserves your intended HTTP method.

Tags

httpredirectiontemporarymethod-preservation

Related Items

More in 3xx Redirection

Frequently Asked Questions

It means the resource is temporarily at another URL and the client must use the exact same HTTP method for the redirected request.