Error Codes Wiki

HTTP 415 Unsupported Media Type — Wrong Content-Type

Warning4xx client error

Overview

HTTP 415 Unsupported Media Type means the server does not support the request Content-Type.

Key Details

  • Status: 415 Unsupported Media Type
  • Category: 4xx Client Error
  • Server cannot process the content type
  • Check Accept and Content-Type headers

Common Causes

  • Sending form data to a JSON-only endpoint
  • Missing Content-Type header
  • Using XML when server expects JSON
  • File type not accepted by upload endpoint

Steps

  1. 1Set Content-Type: application/json for JSON APIs
  2. 2Check API docs for accepted content types
  3. 3Ensure file uploads use multipart/form-data
  4. 4Match the Content-Type to what the server expects

Tags

http-status4xx-client-errorhttp-415httpstatus-code

More in 4xx Client Error

Frequently Asked Questions

Set the correct Content-Type header matching what the API expects.