Free MIME Type Lookup — Find Content-Type by File Extension

Look up the correct MIME type for any file extension. Search 900+ IANA-registered Content-Type values for HTTP, email, and APIs. Free and offline.

Common MIME Types Reference

.json → application/json
.html → text/html
.css → text/css
.js → application/javascript
.png → image/png
.jpg → image/jpeg
.pdf → application/pdf
.txt → text/plain
.xml → application/xml
.zip → application/zip
.svg → image/svg+xml
.woff → font/woff

MIME Type Lookup — Find Content Types by File Extension

When a web server sends a file to a browser, it includes a Content-Type header that tells the browser what kind of data is being delivered. That header value is a MIME type. Get it wrong and browsers may render HTML as raw text, block JavaScript execution, or force downloads instead of inline display. Our free MIME Type Lookup tool lets you instantly find the correct MIME type for any file extension — offline and private.

What Is a MIME Type?

MIME stands for Multipurpose Internet Mail Extensions. Originally designed for email attachments, MIME types are now the universal standard for identifying data formats on the web. A MIME type has two parts separated by a slash:

type/subtype

For example:

  • text/html — HTML document
  • image/png — PNG image
  • application/json — JSON data
  • video/mp4 — MP4 video
  • application/octet-stream — Generic binary file (unknown type)

MIME types are defined by the IANA (Internet Assigned Numbers Authority) and are used in:

  • HTTP Content-Type response headers
  • HTML <input type="file" accept="..."> attributes
  • CSS @font-face src format declarations
  • Email Content-Type headers for attachments
  • fetch() and XMLHttpRequest requests

Common MIME Types Reference

ExtensionMIME TypeUse Case
.htmltext/htmlWeb pages
.csstext/cssStylesheets
.jstext/javascriptScripts
.jsonapplication/jsonAPI responses
.xmlapplication/xmlXML data
.pngimage/pngPNG images
.jpgimage/jpegJPEG images
.webpimage/webpWebP images
.svgimage/svg+xmlSVG graphics
.gifimage/gifGIF animations
.pdfapplication/pdfPDF documents
.mp4video/mp4Video files
.mp3audio/mpegMP3 audio
.woff2font/woff2Web fonts
.zipapplication/zipArchives
.csvtext/csvSpreadsheet data

How to Use the MIME Type Lookup

  1. Type a file extension (with or without the dot, e.g., pdf or .pdf) into the search field
  2. The matching MIME type appears instantly
  3. Click to copy the MIME type string to your clipboard

The tool searches an offline database of 900+ registered MIME types based on the IANA registry. No internet request is needed.

Why the Wrong MIME Type Causes Problems

Missing or incorrect MIME types are a common source of web bugs:

  • application/octet-stream fallback: Servers that don’t know the file type send this generic header, causing browsers to download the file instead of rendering it
  • CSS/JS blocked: Modern browsers enforce MIME type checking (MIME sniffing protection). If your server sends CSS with text/plain, browsers may refuse to apply it
  • CORS errors: Some APIs require the correct Content-Type in requests. Sending text/plain when application/json is expected causes validation failures
  • Font loading failures: Web fonts (WOFF2, WOFF) have specific required MIME types. Incorrect types prevent fonts from loading

Frequently Asked Questions

What’s the difference between application/json and text/json?

application/json is the correct, IANA-standardized MIME type for JSON. text/json is informal and not officially registered. Always use application/json in production APIs and Content-Type headers.

Why does my server send application/octet-stream for everything?

This is the fallback MIME type sent when the server cannot determine the file’s content type. It means “unknown binary data.” You need to configure your server (Nginx, Apache, Express, etc.) to map file extensions to their correct MIME types. Most frameworks handle this automatically for common types.

What MIME type should I use for fonts?

For WOFF2 files: font/woff2. For WOFF: font/woff. For TTF: font/ttf. Modern browsers also accept application/x-font-woff as a legacy fallback, but the font/ MIME types are the current standard.

Is there a difference between text/javascript and application/javascript?

Both work in browsers, but text/javascript is the currently preferred and standardized type as of RFC 9239 (2022), replacing the older application/javascript. Either will work but text/javascript is the modern recommendation.

How do I set MIME types in my web server?

  • Nginx: types { text/css css; application/json json; } block in nginx.conf
  • Apache: AddType application/json .json in .htaccess
  • Express (Node.js): res.setHeader('Content-Type', 'application/json'), or it’s set automatically by res.json()
  • Astro/Vite: Handled automatically for all standard file types

Built by

Lawanya Chaudhari - Software Developer

Lawanya Chaudhari

Software Developer

I'm a Software Developer specializing in Angular, JavaScript, and TypeScript. I have a strong passion for building performant, user-friendly applications and developer tools that enhance productivity.

Code is like humor. When you have to explain it, it’s bad.