This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: image/webp support in mimetypes
Type: enhancement Stage: resolved
Components: Library (Lib) Versions: Python 3.11
Status: closed Resolution: duplicate
Dependencies: Superseder: Support webp and avif image formats in mimetypes
View: 45639
Assigned To: Nosy List: DahlitzFlorian, costela, ivan2, leecatball, methane, waicalibre, xtreak
Priority: normal Keywords: patch

Created on 2019-11-23 22:33 by leecatball, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 22718 closed waicalibre, 2020-11-04 02:39
PR 23034 closed waicalibre, 2020-11-04 02:40
Messages (6)
msg357386 - (view) Author: Lee Ball (leecatball) Date: 2019-11-23 22:33
WebP is currently missing from the list of supported mimetypes.

It's an open source image format, using VP8 or VP8L for image data and RIFF for containers.

Previously, adding webp support was considered in 2011, but wasn't well supported at the time: ( ). In 2019, WebP now enjoys support in major browsers and OSes. Its sister video format WebM was added to mimetypes in 2016 ( ) and has similar support to WebP.

WebP homepage:
WebP source:
RIFF container spec:
VP8 format spec:
msg358862 - (view) Author: Karthikeyan Singaravelan (xtreak) * (Python committer) Date: 2019-12-25 13:14
Similar to previous discussions having an IANA registration would improve the acceptance of the patch to add it. It's still not listed at
msg358902 - (view) Author: Lee Ball (leecatball) Date: 2019-12-27 07:19
Okay, I've opened a bug with WebP team regarding IANA registration:

For what its worth, WebM was added without an IANA registration as a de facto standard. Approval was given in this 2014 comment:

To help support the recognition of WebP as a de facto standard, the image format is currently seeing about the same amount of usage on the web as BMP images, and has seen sharp growth this year, approximately tripling in usage. Data from W3:

Please let me know if there's any data I can provide, or anyone specific I should contact regarding approval.
msg358903 - (view) Author: Lee Ball (leecatball) Date: 2019-12-27 07:20
Sorry, amendment to my last comment: the WebM approval without IANA registration was in msg232095 of
msg380310 - (view) Author: Inada Naoki (methane) * (Python committer) Date: 2020-11-04 02:42
I'm +1 to add it in common types, because webp is really de-facto standard.

If no objection, I will merge this in next week.
msg398433 - (view) Author: Ivan Borshchov (ivan2) Date: 2021-07-28 21:55
Very uncomfortable to work with webp without it And webp is now pretty hyped due to Google's Core Web Vitals update. 
E.g. pretty popular Django Storages relies on python native mimetype module, so because of this bug it always sets default application/octet-stream to AWS headers, so in the end when users click Open Image on new tab they get webp downloaded 🤣🤣🤣
Date User Action Args
2022-04-11 14:59:23adminsetgithub: 83083
2022-02-02 02:52:36eric.araujounlinkissue42205 superseder
2022-02-02 02:51:57eric.araujounlinkissue42049 superseder
2022-02-02 02:51:21eric.araujosetstatus: open -> closed
superseder: Support webp and avif image formats in mimetypes
stage: patch review -> resolved
resolution: duplicate
versions: + Python 3.11, - Python 3.10
2021-10-06 21:19:13costelasetnosy: + costela
2021-07-28 21:55:48ivan2setnosy: + ivan2
messages: + msg398433
2020-11-04 02:42:44methanesetnosy: + methane

messages: + msg380310
versions: + Python 3.10, - Python 3.9
2020-11-04 02:40:40methanelinkissue42205 superseder
2020-11-04 02:40:29waicalibresetpull_requests: + pull_request22052
2020-11-04 02:39:45methanelinkissue42049 superseder
2020-11-04 02:39:26waicalibresetkeywords: + patch
nosy: + waicalibre

pull_requests: + pull_request22051
stage: patch review
2019-12-27 07:20:47leecatballsetmessages: + msg358903
2019-12-27 07:19:29leecatballsetmessages: + msg358902
2019-12-25 13:14:57xtreaksetnosy: + xtreak
messages: + msg358862
2019-11-29 21:21:27DahlitzFloriansetnosy: + DahlitzFlorian
2019-11-23 22:33:02leecatballcreate