Join the AMA (Ask Me Anything) with the Firefox leadership team to celebrate Firefox 20th anniversary and discuss Firefox’s future on Mozilla Connect. Mark your calendar on Thursday, November 14, 18:00 - 20:00 UTC!

Tìm kiếm hỗ trợ

Tránh các lừa đảo về hỗ trợ. Chúng tôi sẽ không bao giờ yêu cầu bạn gọi hoặc nhắn tin đến số điện thoại hoặc chia sẻ thông tin cá nhân. Vui lòng báo cáo hoạt động đáng ngờ bằng cách sử dụng tùy chọn "Báo cáo lạm dụng".

Tìm hiểu thêm

How to force webp images to fallback to jpg

more options

Since Firefox is natively supporting .webp images, they are displayed as webp images on web sites providing this option. How can we force Firefox to fallback to jpg or png images? I know .webp images support is an improvement, but for my case I need to export a lot of pictures from websites using a drag'n drop from Firefox to Windows Explorer. As webp images are not supported natively by Windows, this is useless... I would like to get the standard image instead.

Remark : Before Firefox v70, it was possible to force it tweaking about:config : "image.http.accept" = "image/webp,*/*" > change to "*/*" But this tweak is not working anymore.

Since Firefox is natively supporting .webp images, they are displayed as webp images on web sites providing this option. How can we force Firefox to fallback to jpg or png images? I know .webp images support is an improvement, but for my case I need to export a lot of pictures from websites using a drag'n drop from Firefox to Windows Explorer. As webp images are not supported natively by Windows, this is useless... I would like to get the standard image instead. Remark : Before Firefox v70, it was possible to force it tweaking about:config : "image.http.accept" = "image/webp,*/*" > change to "*/*" But this tweak is not working anymore.

Tất cả các câu trả lời (20)

more options

What if you disable webp more deeply. On some sites, images may be blank/missing if the site doesn't serve a fallback format:

(1) In a new tab, type or paste about:config in the address bar and press Enter/Return. Click the button accepting the risk.

(2) In the search box above the list, type or paste webp and pause while the list is filtered

(3) Double-click the image.webp.enabled preference to switch the value from true to false

(4) Double-click the image.http.accept preference to display a dialog where you can edit the value and try the old edit, then click OK

more options

Indeed this is the workaround I used so far... Maybe I can find a tool to convert webp to jpg... but image quality loss will be unavoidable.

more options

What are you getting now if you disabled webp (step 3 above)?

more options

I wonder whether an add-on could "screenshot" the WebP image and save it as JPEG as a workaround?

more options

Can you post a link to a publicly accessible page (i.e. no authentication or signing on required)?

Do you still get JPG images with an older Firefox version?

It is possible that websites do user agent sniffing and assume that current Firefox releases support WebP images.

more options
more options

I think that the https://www.leroymerlin.fr website gives a JPG image when image.http.accept = */*. The first site looks rather complicated if I check the link in the Inspector. There are JPG links available, but I don't know what triggers what type to use.

more options

In the fist link I get JPG images if I disable WebP in Firefox (image.webp.enabled = false).

In both cases I get JPG images in Firefox 70 when both webp prefs are disabled.

  • image.http.accept = */*
  • image.webp.enabled = false
more options

cor-el said

Can you post a link to a publicly accessible page (i.e. no authentication or signing on required)? Do you still get JPG images with an older Firefox version? It is possible that websites do user agent sniffing and assume that current Firefox releases support WebP images.

The problem with webp is while Firefox will now display this as an image, the format is truly useless in any other context. I have yet to find a web service I use that will allow you to upload webp as an image. And if I cannot *use* an image, I don't want the thing on disk.

Moreover, conversion tools for webp to other formats, I'm finding, DO NOT WORK RELIABLY. OR AT ALL. This very much includes libwebp, which I'd dump in the compost dumpster if only I could.

Supporting webp is fine. Preventing people from working around its lack of tool support, however, is a bug, and needs to be treated as so. The current about:config settings are as useful as a hammer when applied to one's own fingers. Or head.

more options

syldub said

I know .webp images support is an improvement,

People keep saying that, but if, as is true both for you and for me, if a file is inert and useless on your Windows machine (no difference on a Macintosh, BTW), it's not an improvement. Just because the webp is described on Google's site as "lossless" doesn't mean the file isn't useless. At least jpg or png you get *some* pixels you can use. Webp without proper tool support is 100% lossey.

Can someone recommend a Firefox extension to work around what is now broken behavior. Could someone recommend to FF developers that they *not* treat the current implementation as anything but broken? Particularly until there are good tools to convert out of webp into formats that can be used for practical purposes.

more options

Hi rob41, website authors might be perfectly happy you find it harder to re-use their images.

That's not to say there shouldn't be an easier conversion, but some sites don't serve alternative formats, so Firefox can't just turn off WebP support without breaking some sites, although you can try that as a workaround since it could work on sites you care about. (The steps are in earlier replies.)

If you come across a useful converter in your searches, please share.

more options

While I get why some website owners would find "soft DRM" appealing, I don't think there's any need for the browser to prevent conversion of an image between formats. At least as something that an extension can modify behavior on saving of a file.

I'm fine with FF supporting that MIME type as viewable. That is useful. But right now, the format's appeal is mostly *because* it behaves like Digital Rights Management. Even *if* the webp type is, in theory, an open format.

If even GIMP will not open the damn thing, how "open" a format is that?

Được chỉnh sửa bởi rob41 vào

more options

When this thread was active before, I researched JavaScript code to convert webp to PNG, and found the following. I am not sure it can be turned into an extension because it uses compiled (transpiled) code, but maybe someone could do it:

more options

GIMP 2.10 should support the WebP format.

more options

rob41 said

While I get why some website owners would find "soft DRM" appealing, I don't think there's any need for the browser to prevent conversion of an image between formats. At least as something that an extension can modify behavior on saving of a file. I'm fine with FF supporting that MIME type as viewable. That is useful. But right now, the format's appeal is mostly *because* it behaves like Digital Rights Management. Even *if* the webp type is, in theory, an open format. If even GIMP will not open the damn thing, how "open" a format is that?

The latest GIMP (2.10.14) built for MacOS does appear to do the conversion. But having a working conversion too -- likely NOT based on libwebp -- would be an improvement.

more options

jscher2000 said

When this thread was active before, I researched JavaScript code to convert webp to PNG, and found the following. I am not sure it can be turned into an extension because it uses compiled (transpiled) code, but maybe someone could do it:

The repo looks worth looking for. I think that under the hood, it's using the same Google libwebp source code that is failing for me locally when I installed it directly as a binary from Google, or via homebrew.

Current versions of GIMP (2.10.14 I think) seem to work better than whatever I'm installing via homebrew, which fail with cryptic errors.

more options

For my daily browsing activity, I need to see images, no matter if its WebP or standard images. But when I want to download images, I need the standard image. No easy to find a good way to configure Firefox to do so. If I configure "image.webp.enabled" = false, on some websites I may have no images displayed. For instance : https://www.ikea.com/fr/fr/p/ikea-365-ihaerdig-moulin-a-epices-noir-10152875/

It would be great to have a simple extension that could toggle the about:config "image.webp.enabled" value (false / true)... but I know this is not easy since WebExtension.

more options

syldub said

If I configure "image.webp.enabled" = false, on some websites I may have no images displayed. For instance : https://www.ikea.com/fr/fr/p/ikea-365-ihaerdig-moulin-a-epices-noir-10152875/

I may not be able to convert images, but I do recommend that pepper/spice grinder. They last forever. Although, they will never be that clean again. ;-)

(Not sure why the differences, but i get JPG images on that page.)

more options

Quote: (Not sure why the differences, but i get JPG images on that page.)

Do not get confused by seeing a xxx.JPG file getting requested, you need to check this in "Tools -> Page Info -> Media" to see what type you actually have gotten from the server.

Được chỉnh sửa bởi cor-el vào

more options

I was able too download webp files that had jpegs behind them. Now they download as .jpg files, but they are really webp files. Totally useless as are webp files. Chrome still allows me to choose and I have no idea why. I should be able to select save as and it should save as a jpeg, now it says it saves as a webp/jpeg file. Just absolute beyond stupid. This was with my upgrade to Version 74.

  1. 1
  2. 2