mime-types is a Node.js JavaScript utility for resolving MIME content types from file extensions or file paths. It provides functions like lookup(path) to get content types (or false when not found) and contentType(type) to build full Content-Type header values including default charset handling.
Project status
- Actively maintained, with a very recent upstream push on 2026-06-02, and multiple versioned
updatesin 2025. - Update cadence appears uneven but ongoing, with
updatesfor v3.0.0 (2025-03-23), v3.0.1 shortly after (2025-03-26), then v3.0.2 much later (2025-11-20).
AI summary generated Today
Recent updates
v3.0.2
6 months agov3.0.2 updates CI workflows and developer tooling, and includes a functional fix to MIME score logic so `.mp4` resolves to `video/mp4`. It also updates JSDoc type annotations to reflect the actual return shape of lookup helpers.
BreakingSecurityv3.0.1
3/26/2025v3.0.1 is a small maintenance release that updates the mime-db dependency to 1.54.0 and bumps several pinned GitHub Actions versions used by the OSSF Scorecard workflow. The library version was also incremented from 3.0.0 to 3.0.1.
v3.0.0
3/23/2025v3.0.0 introduces a major MIME type resolution change by switching extension conflict handling to a mime-score based algorithm. The release also updates CI to test only modern Node versions, adds OpenSSF Scorecard workflow support, and bumps mime-db to 1.53.0.
BreakingFeatures2.1.35
3/12/2022Release 2.1.35 primarily updates the runtime dependency `mime-db` from 1.51.0 to 1.52.0, which expands MIME type and extension mappings. The documented release notes match the change in `mime-db` content, adding new and updated extensions (including `.asc` for `application/pgp-keys`).
2.1.34
11/9/2021Release 2.1.34 primarily updates the underlying mime database to mime-db@1.51.0, which adds new upstream MIME types. The code diff also shows CI pipeline adjustments for newer Node.js versions and several development dependency version bumps.
Features2.1.33
10/1/2021Release 2.1.33 updates the mime-db dependency from 1.49.0 to 1.50.0. The documented change is the addition of deprecated iWorks MIME types and new upstream MIME types.
2.1.32
7/27/2021Release 2.1.32 bumps the underlying mime-db dependency to 1.49.0 and records the new upstream MIME mappings in release history. The published release notes only mention the `.trig` mapping and additional upstream MIME types.
Features2.1.31
6/1/2021Release 2.1.31 bumps the runtime dependency mime-db to 1.48.0, bringing new MIME associations such as the .mvt extension and additional upstream MIME types. The documented release notes cover only this MIME database update. The code diff also changes CI configuration and developer tooling dependencies that are not mentioned in the release notes.
Features2.1.30
4/2/2021Release 2.1.30 updates the mime-types package dependency on mime-db from 1.46.0 to 1.47.0, which adjusts MIME extension mappings (including audio/amr and application/*+xml handling). The release notes only mention the mime-db changes, while the actual diff also bumps CI Node.js patch versions and upgrades some development dependencies.
2.1.29
2/18/2021Release 2.1.29 primarily updates the underlying mime database to add several new file extension to MIME type mappings. The release notes only mention these MIME type additions via mime-db@1.46.0.
Features