What is a .WEBP file?
A .webp is an image in the WebP format produced by Google for compressing web image size. This kind of image can be successfully processed using the built-in browser decoding in Chrome, Firefox, Edge, and Safari. Extension is used to define one group of formats, but never a number of different formats. An exception can be defined as the case when the .webp is an incorrect file and not a RIFF container with WEBP form.
As mentioned above, WebP is not an ordinary bitmap but rather a RIFF container whose inner chunk structure determines compression type and defines extra information which image will store. Chunk of file may store any of the following elements or combination of these elements: a bitmap representation of static frame, transparency information, an ICC image profile, EXIF and XMP metadata and even the image of frames in an animation. Lossy version uses VP8 intra-frame coding and lossless uses WebP's own prediction, transform and encoding. Extended files use chunks such as VP8X to determine the presence of transparency, metadata, or animation. Animated images have additional ANIM and ANMF chunks. The extension is used for both types of the .webp file.
Most frequent usage is downloading .webp file images from a website or a CMS, an online store, social media service, image CDN and etc. WebP started in 2010 and widely spread now in browser rendered imagery.
How to open a .WEBP file
Open a .WEBP file on Windows
- 1 Go to the folder with your file in File Explorer. Usually, downloaded files end up in Downloads.
- 2 Double-click your .WEBP file if you have an app for .webp files on your computer. In case it does not open, move on to step three.
- 3 Right-click your .WEBP file -> select .
- 4 Choose Google Chrome in the list (Windows 11: choose Always). For Windows 10 -> put a check on "Always use this app to open .webp files" and click OK.
Still not opening? See common problems and fixes, or view it in your browser.
Programs for Windows
- Google Chrome free
- Mozilla Firefox open-source
- Microsoft Edge free
- Adobe Photoshop paid
- GIMP open-source
- libwebp tools open-source
- IrfanView freemium
- XnView MP freemium
Open a .WEBP file on macOS
- 1 In the Finder app, locate your .WEBP file.
- 2 Just double-click your .WEBP file in order to automatically launch the program which is connected with it.
- 3 Need another app on your Mac? Control-click the file (or right-click with a mouse). In the pop-up menu select .
- 4 If it isn't in the list, choose and find the application manually.
Still not opening? See common problems and fixes, or view it in your browser.
Programs for macOS
- Google Chrome free
- Mozilla Firefox open-source
- Microsoft Edge free
- Apple Safari free
- Adobe Photoshop paid
- GIMP open-source
- libwebp tools open-source
- XnView MP freemium
Open a .WEBP file on Linux
- 1 Launch your file manager. Depending on the desktop it may be named Files (GNOME), Dolphin (KDE Plasma), Nemo (Cinnamon) or Thunar (Xfce).
- 2 Double-click the file.
- 3 Or choose another program by right-clicking the file -> .
- 4 Install Google Chrome (if it is not installed on your computer) from the software centre, repository or Flathub.
Still not opening? See common problems and fixes, or view it in your browser.
Programs for Linux
- Google Chrome free
- Mozilla Firefox open-source
- Microsoft Edge free
- GIMP open-source
- libwebp tools open-source
- XnView MP freemium
- ImageMagick open-source
- FFmpeg open-source
Open a .WEBP file on Android
- 1 Launch Files or another file management app.
- 2 In Downloads, find the .WEBP file and open it by tapping.
- 3 A list of apps capable of opening the file will be shown. Tap Google Chrome and press Always to permanently connect the file type with this app.
- 4 No apps able to open this file? Download Google Chrome from the Google Play Store.
Still not opening? See common problems and fixes, or view it in your browser.
Programs for Android
- Google Chrome free
- Mozilla Firefox open-source
- Microsoft Edge free
- Android Gallery / Photos apps free
Open a .WEBP file on iPhone / iPad
- 1 Use the Files app and go to On My iPhone, iCloud Drive or Downloads.
- 2 Tap the .WEBP file you want to open.
- 3 If the file can be opened by a built-in iOS app (supported format), it opens automatically.
- 4 Touch and hold the file to get the context menu -> choose -> select Google Chrome from the list of apps.
- 5 If there is no such option, download the app first from the App Store and then tap the document again.
Still not opening? See common problems and fixes, or view it in your browser.
Programs for iPhone / iPad
- Google Chrome free
- Mozilla Firefox open-source
- Microsoft Edge free
- Apple Safari free
Open a .WEBP file online
- 1 Move to the online viewer at the top of this page.
- 2 Drag the file there or select it, and its contents will appear in your browser tab. The file is not uploaded.
Still not opening? See common problems and fixes, or view it in your browser.
Programs for Online
- Adobe Photoshop paid
More details about opening .WEBP files
Modern web browsers are equipped by built-in ability of opening .webp images files by dropping them on browser windows (tab) or through going File/Open command on the menu bar.
Windows-based platforms enable displaying a WebP file by means of using MS products and modern browsers (Chrome, Firefox, etc.). Desktop viewers like IrfanView, XnView MP, Paint.NET Photoshop/Gimp, or ImageMagick would do the task if necessary.
macOS' browser Safari allows opening WebP files, as well as Preview from modern versions of operating systems and Quick Look utility where available. When Preview fails to perform the operation, other applications should be tried, such as Photoshop, GIMP, XnView MP, or image manipulation tool - ImageMagick. Linux users are advised to launch WebP via modern Firefox and Google Chrome browsers; GIMP image editor, Gwenview / Eye of GNOME (where built), as well as ImageMagick and libwebp command-line converters (dwebp, cwebp).
Platform support from Android OS guarantees the ability to launch .webp via any gallery applications; still animated file type cannot be opened in case of older apps. For iPhones and iPads Safari from current releases is capable of viewing WebP files as well as Photos from new iOS / iPadOS; older OS versions are unlikely to allow the job done unless one finds alternative (such as WebP conversion beforehand).
Using web utilities may turn out helpful for viewing/editing WebP pictures if there is no need of using any desktop software. Chrome, Photopea, and online converters will be able to process .webp images files just fine. If the file will not get launched by double clicking, one should check whether file extension is right (.webp), try running in a browser window, update the program to the latest version, and change .webp association in your OS.
Technical details
A .webp file consists of a RIFF container containing a fixed-length header consisting of ASCII characters of type RIFF, 32-bit little-endian file size starting from offset 4, and the ASCII WEBP of form type at offset 8. MIME-type: image/webp. The extension is mostly .webp, however, some computer operating systems treat both extensions as being equal (both .WEBP, .WebP and .webp). Internally, a WebP file consists of RIFF chunks containing the 4-byte identification number called FourCC, a little-endian-length value followed by a padding, and chunk content which is padded to an even byte boundary.
The first WebP-specific data in a file comes with the chunks labeled either VP8 (lossy still image data), VP8L (lossless still image data), or VP8X (extended data indicating alpha channels, animations, ICC Profile, EXIF metadata and or XMP). This type of chunks contains canvas width-height, which for WebP can take very large dimensions because the specification supports very large dimensions; however, there are real-world limitations in the amount of used memory to decode a file.
In terms of compression algorithm, the lossy mode employs VP8 key-frame coding, which consists of using the same set of blocks (macroblocks) or smaller, with a predictor transform, then using forward transform coding and applying quantization. For lossless encoding, a file uses a completely different path and performs a predictor transform and color transform as well as subtract-gree color coding, color index and back-reference with huffman-like (entropy) code. An additional chunk used for representing alpha-channel either is located in ALPH chunk or located in the main VP8L data (lossless file).
Animated WebPs use an extension consisting ANIM and one or more of ANMF chunks describing the background, loop count, frame rectangles, and frame durations of each animation chunk. Metadata of any sort are stored in ICCP (color), EXIF (information about the place of picture creation etc) and XMP chunks storing embedded document metadata. Sometimes, during editing the file encoder drops all the extra chunks. The common file sizes range from under 10 KB (as an icon) up to several megabytes in case of a multiframe animation.
How to convert .WEBP files
Use cwebp to convert to WebP format from another format. You have to convert a still WebP into PNG when you need full editor support, transparency, or a lossless conversion. With libwebp, you can use dwebp input.webp -o output.png to convert straight into PNG, and it also supports writing into PAM, PPM, or PGM formats. The conversion should be into JPEG format if you are dealing with an older version of document software, email gateways, and websites that do not accept image/webp but note that alpha channel will be removed.
To convert an animated WebP file into GIF file, it is recommended that the old platform accepts it because it supports only 256 colors palette. To do that use ffmpeg -i input.webp output.gif, but it results in a large file as compared to the animated WebP file. It is more recommended that you convert it to MP4 or WebM format when you are using video platform or for having control over the playback. The conversion from WebP to MP4 is done using ffmpeg -i input.webp -movflags +faststart -pix_fmt yuv420p output.mp4.
Use cwebp to create a WebP format and ImageMagick for batch resizing and format changes into one single operation. Remember that ICC, EXIF and XMP metadata can be optionally preserved while performing conversion.
| Convert to | Tool | Command / note |
|---|---|---|
| PNG | dwebp | dwebp input.webp -o output.png Best common target for lossless conversion or transparency; animation is not preserved by a single PNG. |
| JPEG | ImageMagick | magick input.webp -quality 90 output.jpg Useful for older software, but transparency and animation are lost and lossy recompression may add artifacts. |
| AVIF | ImageMagick | magick input.webp -quality 50 output.avif AVIF can be smaller at similar quality but may encode more slowly and has different compatibility. |
| GIF | FFmpeg | ffmpeg -i input.webp output.gif Useful for animated WebP compatibility; GIF is limited to 256-color palettes and often much larger. |
| WebP from PNG | cwebp | cwebp -q 80 input.png -o output.webp Creates a lossy WebP; add -lossless for exact pixel preservation where supported. |
| WebP from JPEG | cwebp | cwebp -q 80 input.jpg -o output.webp Often reduces file size for web delivery; source JPEG artifacts remain. |
| MP4 | FFmpeg | ffmpeg -i input.webp -movflags +faststart -pix_fmt yuv420p output.mp4 Practical for animated WebP playback in video workflows; still-image alpha is not retained in standard H.264 MP4. |
Common problems and fixes
"File format not recognized" or "not a RIFF file" implies damaged .webp file before the beginning of the RIFF header with an offset of 0, erroneous extension or web server error saving a web error page as image data. The user should double-check the file size against its original source file, refresh and re-download the webpage from where the download link was used. In the case when the start of the downloaded file does not contain bytes 52 49 46 46 but contains some HTML code, one should try re-downloading it. When Windows shows pop-up that another application should be selected, the preferred file opening method may be modified in the settings menu under Open with.
An obsolete editor that reports "Unsupported image format" requires software upgrades to include WebP support or use an alternative file decoder/ viewer altogether. Nowadays, Google Chrome, Microsoft Edge, Mozilla Firefox and Safari browser versions, as well as GIMP, Adobe Photoshop and XnView MP graphics programs can natively open .webp image files, whereas testing a doubtful image should be best done in any browser window. In case the image seems still, it could possibly be an Animated version of the file - the browser or using FFmpeg or any recent build of an ImageMagick package capable of handling WebP animations will display all the frames of the images. Pure color (black/white) or non-existent background most likely means transparency is stripped in the process and should be converted to PNG using dwebp input.webp -o output.png to create the .png copy. Washout appearance suggests absence of an ICC profile, and conversion through color-aware programs should preserve ICC info in its new destination format. Very large resolution or maliciously created files may overflow the limited decoder memory and should be resized before conversion. The latest versions of the library, browser, and graphics applications must be installed always. Web-based forms on sites do not accept files only because most of them are hosted and built by CMS systems that only accept JPEG or PNG formats.
Security considerations
"WebP is merely a container, which doesn't contain any sort of macro commands or script codes as compared to document formats such as Office files and PDF." There exist mainly one risks related to decoders. It's necessary that the browser Chrome, Firefox, Safari, Edge or the libwebp, ImageMagick, GIMP, Photoshop and various other libraries and programs, dealing with the conversion of the images must receive patches and should not include vulnerabilities, since one example of such CVE-2023-4863 in libwebp consists of the bug of "Heap based buffer overflow". Various data in EXIF and XMP fields include information about cameras used as well as about creation of the image, timestamps as well as the name of the creator. While the use of the .webp file locally will prevent the communication with internet sites, loading such files remotely can help track activity of users. Strip metadata before publishing sensitive images.
History and versions
WebP was announced by Google in 2010 as an image format based on VP8 codec, which was the video coding format for the WebM project developed by Google. The development started off with focusing on web-based lossy compression in contrast with JPEG as per photographic web pages, and in doing so intended to save bandwidth compared with JPEG. However, after a few months in the year of 2011, they extended WebP with lossless and alpha transparency for graphics. This was followed later by animated WebP support.
Chrome supported WebP early. Later on, WebP gained additional support through other major web browsers such as Firefox and Edge. Apple Safari began supporting WebP on Apple platforms with Safari 14. Google documents about the WebP format and container documentation are available publicly. In addition, a reference C library for WebP was made available in the open source format by Google. Although it's not an official ISO like JPEG 2000, WebP continues being a de facto standard on web.
Related formats
The most widely supported yet outdated JPEG (.jpg, .jpeg) cannot store alpha transparency and does not allow saving files that would be small enough in size compared to files of the same visual quality in the WebP format. Though the lossless format and perfect format of choice when using transparent art or taking screenshots is PNG (.png), pictures saved as WebP images are much smaller in the case of PNG ones. The animated GIF file (.gif), however, uses only up to 256 colors per frame while WebP offers even better quality in less capacity. Though AVIF (.avif) usually offers much better performance comparing with WebP, it can include HDR-related features and encoding is longer. JPEG XL (.jxl) stands out for advanced capabilities but its adoption in browsers is insufficient now. HEIC/HEIF (.heic) is widely used in Apple devices; yet it faces patent and compatibility issues. The format WebM (.webm) is rather a video container.
No comments yet. Be the first to share your experience with this file type.