Skip to content
ZeroServer.tools

MIME Type Lookup

Find the MIME type for a file extension, or the extensions for a MIME type.

ExtensionMIME type
.txttext/plain
.htmltext/html
.csstext/css
.csvtext/csv
.mdtext/markdown
.icstext/calendar
.jstext/javascript
.mjstext/javascript
.jsonapplication/json
.xmlapplication/xml
.yamlapplication/yaml
.ymlapplication/yaml
.wasmapplication/wasm
.pdfapplication/pdf
.rtfapplication/rtf
.zipapplication/zip
.gzapplication/gzip
.tarapplication/x-tar
.7zapplication/x-7z-compressed
.rarapplication/vnd.rar
.binapplication/octet-stream
.docapplication/msword
.docxapplication/vnd.openxmlformats-officedocument.wordprocessingml.document
.xlsapplication/vnd.ms-excel
.xlsxapplication/vnd.openxmlformats-officedocument.spreadsheetml.sheet
.pptapplication/vnd.ms-powerpoint
.pptxapplication/vnd.openxmlformats-officedocument.presentationml.presentation
.pngimage/png
.jpgimage/jpeg
.jpegimage/jpeg
.gifimage/gif
.svgimage/svg+xml
.webpimage/webp
.avifimage/avif
.apngimage/apng
.bmpimage/bmp
.icoimage/vnd.microsoft.icon
.tiffimage/tiff
.mp3audio/mpeg
.wavaudio/wav
.oggaudio/ogg
.aacaudio/aac
.webaaudio/webm
.mp4video/mp4
.webmvideo/webm
.mpegvideo/mpeg
.movvideo/quicktime
.avivideo/x-msvideo
.wofffont/woff
.woff2font/woff2
.ttffont/ttf
.otffont/otf
.eotapplication/vnd.ms-fontobject

What is a MIME type?

A MIME type (also called a media type or content type) tells browsers and servers what kind of data a file contains, such as text/html or image/svg+xml. It is sent in the Content-Type response header and decides how the content is handled — rendered, downloaded, or executed. Getting it right matters for security and for features like inline previews and font loading.

Setting response headers? Pair this with the HTTP status code reference. Encoding a file inline? The SVG to data URI and Base64 tools include the right MIME type for you.

Built and maintained by Meet Shah · Last updated

What this tool is used for

  • Finding the correct MIME type for a file extension.
  • Finding which extensions a MIME type covers.
  • Checking a type before setting a content-type header.
  • Confirming the type a server should send for an asset.
  • Resolving a download that opens in the browser instead of saving.

Frequently Asked Questions

What is a MIME type for?
It tells the recipient how to interpret bytes. Browsers act on the `Content-Type` header, not the file extension, so serving a stylesheet as `text/plain` means it is downloaded or ignored rather than applied.
Why is JavaScript listed as text/javascript?
Because that is what the current specification requires. `application/javascript` and `application/x-javascript` are both obsolete though still widely accepted; the HTML standard designates `text/javascript` as the one to use.
Do I need charset on a text type?
Yes for anything textual. Without `; charset=utf-8` the browser falls back to a default that may not be UTF-8, which is how correct source files end up rendering as mojibake. It is unnecessary for binary types.
Why are Office types so long?
They are vendor-registered types under the `vnd.` tree, and the OOXML names encode the whole format lineage. The legacy binary formats are much shorter — `application/msword` for .doc against the full `openxmlformats` string for .docx.
What does application/octet-stream mean?
"Unknown bytes." It is the correct fallback when the type genuinely is not known, and it usually triggers a download prompt. Using it as a lazy default for a known type defeats caching and inline display.
Can one extension have several types?
Yes, and the reverse too. `.ogg` may be audio or video, and both `.jpg` and `.jpeg` are `image/jpeg`. Where a mapping is ambiguous the server's configuration decides, which is why explicit `types` blocks are worth setting.

Common errors and gotchas

  • Trusting a client-supplied type, which is trivially forged and must never gate an upload.
  • Using a non-standard type where a registered one exists, which some clients reject.
  • Omitting the charset on a text type, which leaves the encoding to a guess.
  • Assuming the extension determines the type, when the bytes are what actually matter.
  • Serving a JavaScript module with the wrong type, which browsers refuse to execute.

Related Developer Utilities tools

Private & free — this tool runs entirely in your browser.

IndieKitShip your Next.js startup in days.affiliate