MIME Types Reference
Complete MIME type reference with file extensions and descriptions. Essential for HTTP headers, file uploads, API development, and server configuration.
Text
| MIME Type | Extension(s) | Description |
|---|---|---|
| text/plain | .txt | Plain text without any formatting or markup |
| text/html | .html, .htm | HTML documents — the standard markup for web pages |
| text/css | .css | Cascading Style Sheets for styling HTML documents |
| text/javascript | .js, .mjs | JavaScript source code (preferred over application/javascript) |
| text/csv | .csv | Comma-separated values — tabular data in plain text |
| text/xml | .xml | XML documents (text-readable variant; see also application/xml) |
| text/markdown | .md, .markdown | Markdown formatted text documents |
| text/calendar | .ics | iCalendar scheduling and event data |
| text/tab-separated-values | .tsv | Tab-separated values for tabular data |
| text/rtf | .rtf | Rich Text Format — formatted text with basic styling |
Application
| MIME Type | Extension(s) | Description |
|---|---|---|
| application/json | .json | JSON data — the most common format for APIs and configuration |
| application/xml | .xml | XML documents (application variant — preferred for non-human-readable XML) |
| application/pdf | Portable Document Format — fixed-layout documents | |
| application/zip | .zip | ZIP compressed archive |
| application/gzip | .gz | Gzip compressed file |
| application/x-tar | .tar | Tape archive (uncompressed) |
| application/x-7z-compressed | .7z | 7-Zip compressed archive |
| application/x-rar-compressed | .rar | RAR compressed archive |
| application/octet-stream | (any) | Arbitrary binary data — used when the exact type is unknown |
| application/x-www-form-urlencoded | — | HTML form data encoded as key=value pairs (default form encoding) |
| application/javascript | .js | JavaScript (legacy MIME; text/javascript is now preferred) |
| application/typescript | .ts | TypeScript source code |
| application/ld+json | .jsonld | JSON-LD linked data (used for structured data / SEO) |
| application/graphql | .graphql | GraphQL query language documents |
| application/wasm | .wasm | WebAssembly binary module |
| application/vnd.ms-excel | .xls | Microsoft Excel spreadsheet (legacy format) |
| application/vnd.openxmlformats-officedocument.spreadsheetml.sheet | .xlsx | Microsoft Excel spreadsheet (modern Open XML format) |
| application/vnd.ms-powerpoint | .ppt | Microsoft PowerPoint presentation (legacy) |
| application/msword | .doc | Microsoft Word document (legacy) |
| application/vnd.openxmlformats-officedocument.wordprocessingml.document | .docx | Microsoft Word document (modern Open XML format) |
Image
| MIME Type | Extension(s) | Description |
|---|---|---|
| image/png | .png | Portable Network Graphics — lossless compression with transparency |
| image/jpeg | .jpg, .jpeg | JPEG image — lossy compression, ideal for photographs |
| image/gif | .gif | Graphics Interchange Format — supports animation and transparency |
| image/webp | .webp | WebP — modern format with superior lossless and lossy compression |
| image/svg+xml | .svg | Scalable Vector Graphics — XML-based vector image format |
| image/avif | .avif | AV1 Image Format — next-gen format with excellent compression |
| image/bmp | .bmp | Bitmap image — uncompressed raster format |
| image/x-icon | .ico | ICO format — used for favicons and Windows icons |
| image/tiff | .tiff, .tif | Tagged Image File Format — high-quality lossless images |
| image/heic | .heic, .heif | High Efficiency Image Format — used by Apple devices |
| image/apng | .apng | Animated PNG — animated images with better quality than GIF |
Audio
| MIME Type | Extension(s) | Description |
|---|---|---|
| audio/mpeg | .mp3 | MP3 audio — the most widely supported lossy audio format |
| audio/ogg | .ogg, .oga | Ogg Vorbis audio — open-source lossy audio format |
| audio/wav | .wav | Waveform Audio — uncompressed PCM audio |
| audio/webm | .weba | WebM audio — open format based on Opus or Vorbis codec |
| audio/aac | .aac | Advanced Audio Coding — better quality than MP3 at similar bitrates |
| audio/flac | .flac | Free Lossless Audio Codec — lossless compression |
| audio/midi | .mid, .midi | MIDI audio — musical instrument digital interface data |
| audio/opus | .opus | Opus audio — versatile codec for speech and music |
| audio/mp4 | .m4a | MPEG-4 audio — commonly AAC encoded |
Video
| MIME Type | Extension(s) | Description |
|---|---|---|
| video/mp4 | .mp4, .m4v | MPEG-4 video — the most widely supported video format on the web |
| video/webm | .webm | WebM video — open format with VP8/VP9/AV1 codecs |
| video/ogg | .ogv | Ogg Theora video — open-source video format |
| video/x-msvideo | .avi | Audio Video Interleave — Microsoft multimedia container |
| video/quicktime | .mov | QuickTime video — Apple's multimedia container format |
| video/x-matroska | .mkv | Matroska video — flexible open container format |
| video/x-flv | .flv | Flash Video — legacy streaming format |
| video/mpeg | .mpeg, .mpg | MPEG video — original MPEG-1/MPEG-2 format |
| video/3gpp | .3gp | 3GPP video — mobile multimedia format |
Multipart
| MIME Type | Extension(s) | Description |
|---|---|---|
| multipart/form-data | — | Form data with file uploads — uses boundary delimiters to separate fields |
| multipart/byteranges | — | HTTP response with multiple byte ranges (used with 206 Partial Content) |
| multipart/mixed | — | Message containing multiple body parts of different types (email attachments) |
| multipart/alternative | — | Same content in different formats (e.g., plain text + HTML email) |
| multipart/related | — | Body parts that are related to each other (e.g., HTML + inline images) |
| multipart/signed | — | Digitally signed message with signature as separate part |
| multipart/encrypted | — | Encrypted message content |
Font
| MIME Type | Extension(s) | Description |
|---|---|---|
| font/woff | .woff | Web Open Font Format — compressed font with metadata |
| font/woff2 | .woff2 | WOFF 2.0 — improved compression over WOFF (preferred for web) |
| font/ttf | .ttf | TrueType Font — widely supported outline font format |
| font/otf | .otf | OpenType Font — extends TrueType with advanced typographic features |
| font/sfnt | .sfnt | SFNT container — generic wrapper for font tables |
| font/collection | .ttc, .otc | Font collection — multiple fonts bundled in a single file |
| application/vnd.ms-fontobject | .eot | Embedded OpenType — legacy IE web font format |
Frequently Asked Questions
What is a MIME type and why does it matter?
A MIME type (Multipurpose Internet Mail Extensions) is a label that identifies the format of data sent over the internet. Browsers and servers use it to decide how to handle a file — for example, rendering HTML, playing audio, or triggering a download. Setting the correct Content-Type header prevents rendering issues and security vulnerabilities.
What is the difference between text/javascript and application/javascript?
Both refer to JavaScript, but text/javascript is now the official standard (per RFC 9239). application/javascript was used historically and is still widely accepted, but text/javascript is recommended for new projects and is what browsers expect.
When should I use application/octet-stream?
Use application/octet-stream as a fallback when the exact MIME type is unknown or when you want to force a file download. The browser treats it as arbitrary binary data and typically offers a save dialog rather than trying to display it.
Which image format should I use for the web?
Use WebP or AVIF for the best compression-to-quality ratio. Use SVG for icons, logos, and illustrations. JPEG is ideal for photographs when broad compatibility is needed. PNG is best when you need lossless quality with transparency. Use the <picture> element to serve modern formats with fallbacks.