---
title: OPTIMIZED_EXTERNAL_IMAGE_TOO_MANY_REDIRECTS
product: vercel
url: /docs/errors/OPTIMIZED_EXTERNAL_IMAGE_TOO_MANY_REDIRECTS
type: reference
prerequisites:
  []
related:
  []
summary: The external image request encountered too many redirects. This is a request error.
install_vercel_plugin: npx plugins add vercel/vercel-plugin
---

# OPTIMIZED_EXTERNAL_IMAGE_TOO_MANY_REDIRECTS

The `OPTIMIZED_EXTERNAL_IMAGE_TOO_MANY_REDIRECTS` error occurs when the external image request encounters too many redirects.

**Error Code:** `502`

**Name:** Bad Gateway

## Troubleshoot

To troubleshoot this error, follow these steps:

1. **Check URL for redirects:** Verify the external image URL to ensure it does not cause an infinite redirect loop


---

[View full sitemap](/docs/sitemap)
