Media type / application
application/vnd.api+json
JSON:API — a convention for resource documents, relationships, and pagination over HTTP.
Served inline: Browsers have no renderer for this, so it downloads even without a Content-Disposition header. That makes it the quiet default for anything you do not want opened in place.
Browser behaviour
Downloads
Charset
charset ignored
Compression
Compress in transit
Send it like this
Content-Type: application/vnd.api+jsonThe format defines its own encoding, so no charset parameter is registered for this type. Sending one is harmless, but receivers are required to ignore it — it is not doing what people think it does.
Handling verdict
Browsers have no renderer for this, so it downloads even without a Content-Disposition header. That makes it the quiet default for anything you do not want opened in place.
The format defines its own encoding, so no charset parameter is registered for this type. Sending one is harmless, but receivers are required to ignore it — it is not doing what people think it does.
The payload is text-like or otherwise repetitive, so gzip or Brotli removes real bytes. Enable it at the server or CDN.
A `vnd.` subtype belongs to a specific product or organisation. It is registered, but its meaning is defined by that vendor rather than by a standards body.
Anatomy of the name
RFC 6838Top-level type
application
Application
Subtype
vnd.api+json
Registered in the vendor tree.
Structured syntax
+json
Any client that can parse JSON can read the payload, even without understanding this specific type.
Parameters
none
Beyond the charset rule above, this type defines no parameters of its own.
What trips people up
1 note- The spec requires servers to reject requests that send this type with any media type parameters.
Response headers
Content-Type: application/vnd.api+json
X-Content-Type-Options: nosniff
Content-Disposition: attachment; filename="example"
Vary: Accept-Encodingnosniff stops the browser second-guessing the type you declared, which is what makes the rest of this reliable. Content-Disposition: attachment names the saved file and removes any doubt about rendering.
Server configuration
route headernginx
# application/vnd.api+json has no file extension — set it on the route instead
add_header Content-Type "application/vnd.api+json";Apache
# application/vnd.api+json has no file extension — set it on the handler instead
Header set Content-Type "application/vnd.api+json"Caddy
header Content-Type "application/vnd.api+json"