HTTP Status Codes / 2xx HTTP Status Codes / HTTP 202

202 Accepted

This is an educational reference page about HTTP 202 Accepted. The page itself is served as 200 OK so it can be indexed as HTTP documentation.

The server accepted the request for processing but has not finished it. The work may still fail or be rejected later.

Specification

Registered in the IANA HTTP Status Code Registry as Accepted. Defined in RFC 9110, Section 15.3.3.

What it means

HTTP 202 Accepted means the server accepted the request but has not finished processing it. RFC 9110 calls 202 intentionally noncommittal: the request might still be rejected when the work runs, and HTTP has no way to send a second status code when the background job finishes.

When to use it

Headers involved

Examples

Start an export job

POST /api/exports HTTP/1.1
Host: api.example.com
Content-Type: application/json

{
  "format": "csv",
  "range": "2026-Q3"
}

HTTP/1.1 202 Accepted
Location: /api/exports/jobs/7781
Retry-After: 10
Content-Type: application/json

{
  "jobId": "7781",
  "status": "queued",
  "statusURL": "/api/exports/jobs/7781"
}

Poll the job status

GET /api/exports/jobs/7781 HTTP/1.1
Host: api.example.com

HTTP/1.1 200 OK
Content-Type: application/json

{
  "jobId": "7781",
  "status": "done",
  "download": "/api/exports/7781.csv"
}

Common mistakes

Developer notes

With 202, the HTTP exchange ends before the work does, so the job's outcome has to come from somewhere else: a status endpoint the client polls, a webhook, or an email. The status endpoint itself returns normal codes, usually 200 with a status field that tells the client whether the job is queued, running, done, or failed.

Questions

What does HTTP 202 Accepted mean?

HTTP 202 means the server accepted the request for processing but has not finished it. The final outcome is reported another way, such as a status URL.

Should an async API return 202 or 201?

Return 202 when the resource is created later by a background job. Return 201 when the resource exists when you send the response.

See also

Header and content rules

What RFC 9110 says about a 202 response, quoted from the RFC.

The same rule is in the response obligations table and its JSON.

2xx successful – the request was successfully received, understood, and accepted


HTTP status code lookup
REST API status code chooser
cURL command generator
By Ping Now, a website/API/service uptime monitor
Data from Wikipedia