TToolbox
MIME

MIME Type Lookup

Search by file extension or media type

About this tool

Multipurpose Internet Mail Extensions (MIME types, managed by IANA and RFC 6838, known as Content-Type in HTTP) dictate how web browsers decode and render received data payloads. Whether configuring Nginx server blocks, validating file upload security headers, or consuming REST endpoints, MIME headers prevent corrupted downloads and layout failures. This tool provides bidirectional lookup between file extensions and authoritative MIME types.

How to Use This Tool (Step-by-Step)

1

Enter File Extension or MIME String

Type an extension (e.g., `.pdf`, `.svg`, `.wasm`) or a MIME category (`application/json`) into the instant search bar.

2

Inspect Media Classification

The tool immediately filters matching entries, grouping them under top-level media classes alongside description notes.

3

Copy Standard Content-Type Header

Copy the canonical Content-Type string with one click for direct inclusion in Nginx mime.types, Express.js, or AWS S3 metadata.

Exhaustive IANA Official Registry

Includes common images/videos alongside modern WebAssembly (`.wasm`), WOFF2 webfonts, and enterprise archive standards.

Bidirectional Fuzzy Search

Seamlessly search by file suffix to find the correct HTTP response header, or query by MIME token to view matching extensions.

100% Client-Side Instant Filtering

Powered by an optimized client-side trie dictionary. Searches execute instantly in memory without external network calls.

MIME Sniffing Vulnerabilities & Nginx Tips

  • •Always set `X-Content-Type-Options: nosniff`: Without this header, browsers execute malicious scripts disguised as images (MIME sniffing).
  • •Append `charset=utf-8` on text types: Without explicit UTF-8 declarations, browsers fall back to legacy system codepages, mangling non-ASCII characters.
  • •Use `application/octet-stream` for forced downloads: This generic binary MIME type forces browsers to save the file rather than rendering it in-tab.

Code & Transformation Examples

High-Frequency Web MIME Types Cheat Sheet

File Extensions
• .html / .htm : 网页文档
• .js / .mjs   : JavaScript 脚本
• .json        : JSON 结构化数据
• .css         : CSS 样式表
• .webp / .svg : 现代图片与矢量图
• .woff2       : 现代网页压缩字体
Standard HTTP Content-Type Header
• text/html; charset=utf-8
• text/javascript
• application/json; charset=utf-8
• text/css
• image/webp  |  image/svg+xml
• font/woff2

* RFC 9239 officially standardized on `text/javascript`, deprecating older `application/javascript` declarations.

Nginx & Node.js Content-Type Setup Snippet

Node.js HTTP Server
res.writeHead(200, { 'Content-Type': 'application/json; charset=utf-8' });
res.end(JSON.stringify({ code: 200, message: "OK" }));
Nginx mime.types
http {
  include       /etc/nginx/mime.types;
  default_type  application/octet-stream;
}

* Incorrect MIME types cause browsers to block stylesheets under strict MIME sniffing policies.

Frequently Asked Questions

Q: Why did my CSS fail with a 'Strict MIME type checking' error?

A: Your server returned `text/plain` instead of `text/css`. Modern browsers refuse to execute stylesheets that fail strict MIME type validation.

Q: What is the `multipart/form-data` MIME type in forms?

A: It is the composite MIME type for uploading binary files alongside form fields, separating parts with random boundary delimiter strings.

Q: What are the canonical MIME types for web fonts?

A: RFC 8081 standardized the top-level `font/` tree: WOFF2 is `font/woff2`, WOFF is `font/woff`, TTF is `font/ttf`, and OTF is `font/otf`.

Related Tools

All processing happens locally in your browser. Your data is never uploaded to a server.
/