HTTP

HTTP 308 Permanent Redirect vs 402 Payment Required

HTTP 308 (Permanent Redirect) is a 3xx Redirection response, while 402 (Payment Required) is a 4xx Client Error response. 308 indicates that the resource has been permanently moved. Like 301, but guarantees the HTTP method will NOT be changed. In contrast, 402 means that reserved for future use. Originally intended for digital payment systems, some APIs use it to indicate a billing or subscription issue.

Description

The resource has been permanently moved. Like 301, but guarantees the HTTP method will NOT be changed.

When You See It

For permanent URL changes where POST requests must remain POST.

How to Fix

Update all references to the new URL. The HTTP method is preserved.

Description

Reserved for future use. Originally intended for digital payment systems, some APIs use it to indicate a billing or subscription issue.

When You See It

On some APIs when a subscription has expired or payment is needed.

How to Fix

Check your billing status, update payment method, or upgrade your subscription.

Key Differences

1.

308 is a 3xx Redirection response, while 402 is a 4xx Client Error response.

2.

HTTP 308: The resource has been permanently moved. Like 301, but guarantees the HTTP method will NOT be changed.

3.

HTTP 402: Reserved for future use. Originally intended for digital payment systems, some APIs use it to indicate a billing or subscription issue.

4.

You encounter 308 when for permanent URL changes where POST requests must remain POST.

5.

You encounter 402 when on some APIs when a subscription has expired or payment is needed.

When to Use Which

For 308 (Permanent Redirect): Update all references to the new URL. The HTTP method is preserved. For 402 (Payment Required): Check your billing status, update payment method, or upgrade your subscription.

Learn More