MIME Type Lookup
Look up MIME types by extension.
About this tool
Enter a file extension, with or without the dot, and get its MIME type, for example.webp gives image/webp. It covers 41 common web, font, image, audio, video and document extensions, and also accepts a whole filename such as photo.PNG; anything else returns application/octet-stream.
How to use
How it works
A MIME type tells a browser how to treat a file. The built-in table covers html, htm, css, js, mjs, json, xml, pdf, zip, png, jpg, jpeg, gif, webp, svg, ico, txt, csv, mp4, mp3, wasm, avif, bmp, tif, tiff, woff, woff2, ttf, otf, md, yaml, yml, webm, wav, ogg, gz, tar, doc, docx, xls and xlsx. Lookup is case-insensitive.
Worked example
A WebP image
- Input
- .webp
- Output
- image/webp
- Walkthrough
- Use Content-Type: image/webp. An unlisted extension such as.xyz returns application/octet-stream, the generic binary type.
Limitations
- Only 41 extensions. Less common ones such as.rar,.7z,.epub and.heic are not included.
- Extension to MIME only; there is no MIME to extension search.
- The fallback application/octet-stream also means the extension is unknown.
Questions
What is the MIME type of a JSON file?
What is the MIME type for JavaScript?
Why do I get application/octet-stream?
Does it need the leading dot?
Features
- 41 common extensions
- Case-insensitive
- Runs in your browser
Related resources
Guides and videos from around the web—opens on YouTube or the publisher’s site.
What Is A RESTful API?
Traversy Media
API context for JWT, JSON, and encoding utilities.
Watch on YouTubeInspect Network Activity - Chrome DevTools 101
Chrome for Developers
Debugging payloads you paste into JSON and JWT tools.
Watch on YouTube
- Introducing JSON
json.org
Canonical JSON grammar for formatters and validators.
- Regular expressions
MDN
JS regex guide aligned with browser-based testers.