Title graphic: Data formats at a glance, file types, conversion & sizes

Web & Tech

Data formats: the essential file types, conversion and file sizes explained

By Daniel Ohiggins · Published: September 12, 2026 · 17 min read

The most important file types at a glance

A file always consists of two layers: the format, which determines how the data is stored internally, and the file extension such as .jpg or .pdf, the visible label on the name. For practice, four questions matter most: Can I open the file everywhere, in other words how high is the compatibility? How large will it be? Can I continue editing it? And does the quality remain?

Color-coded documents and files, organized in trays

FormatCategoryCompressionTransparencyTypical sizeMain use
JPG/JPEGRaster imagelossynosmartphone photo approx. 2 to 5 MBphotos, web, email
PNGRaster imagelosslessyeslogo or screenshot approx. 20 KB to 2 MBgraphics, screenshots, logos
GIFRaster imagelossless, max. 256 colorsyes, 1 bitanimated usually 1 to 15 MBshort animations, memes
WebPRaster imageboth possibleyes25 to 34 % smaller than JPG (2026)web images
SVGVector graphiclosslessyesicon approx. 1 to 50 KBlogos, icons, scalable graphics
PDFDocumentpartly lossyn/atext page approx. 50 to 300 KBprint, final documents, archive
DOCXText documentZIP-basedn/aletter without images approx. 10 to 200 KBeditable text
XLSXSpreadsheetZIP-basedn/asmall table under 100 KBcalculations, evaluations
TXTPlain textnonen/aa few bytes to MBnotes, logs, code
CSVText datanonen/a1,000 rows roughly 30 to 150 KBdata exchange, export
ZIPContainer/archivelossless, DEFLATEn/asaves 0 to 80 % depending on contentbundling, sending
MP3Audiolossyn/a128 kbit/s around 1 MB per minutemusic, podcasts
MP4Video containerlossyn/a5 Mbit/s around 37.5 MB per minutevideos of all kinds
HEICRaster imagelossy, efficientyesaround half the size of JPGiPhone photos since iOS 11

Of these formats, PNG and JPEG continue to dominate the web. According to the latest counts from W3Techs, around 75.5 % of all websites deliver PNG, 69.4 % JPEG, SVG 67.7 %, the modern WebP 21.8 %, GIF still 13.5 % and AVIF 1.7 % (Sep 2026). The WebP figure measures how many websites deliver the format. Browser support is much higher and stands at over 96 % (Mar 2026).

Lossless or lossy: the golden rule

Whether a file loses quality during editing and conversion is decided by compression. In lossy compression such as JPG, MP3 or MP4, data is removed that the eye or ear barely notices, which makes the file clearly smaller. In lossless storage such as PNG or ZIP archiving, every piece of information remains, which makes the file larger or only compresses to a limited extent.

The golden rule: as long as you keep editing a file, work losslessly and therefore in a working format such as PNG, DOCX or XLSX. Only at the end, when the result is final, convert to a lossy target such as JPG, WebP or PDF for web, email or distribution. Repeatedly saving as JPG degrades the image with every pass, this is called the generation effect, and no later conversion brings that damage back.

Converting data: the right conversion paths

Many problems arise because the wrong pair of source and target format is chosen. A rule of understanding helps: the more similar two formats are, the cleaner the conversion. Raster images are best converted into other raster images, for example with the free image converter from JPG to PNG or WebP. Photos and scans can be combined into a single document with images to PDF, for example for an application or an authority submission.

Colorful programming code on a screen, close-up

FromToCleanly possibleCaution
JPGPNGyes, lossless, but becomes largerquality does not improve
JPGWebPyes, clearly smalleronly for web, not for print
HEICJPGyes, needed for exchangecommon with iPhone
PNGWebPyes, lossless possibletest with the image
DOCXPDFyes, ideal for the finalcheck layout
PDFimagesyes, per pagebetter use pdf-tools
CSVJSONyes, losslessmind separators
JSONYAMLyes, losslessmind indentation
XMLJSONyes, losslessattributes partly lost
MarkdownHTMLyes, losslesscontent pipeline

For data exchange between systems, CSV, JSON and XML are the typical partners. The CSV-JSON converter exchanges them losslessly, JSON to YAML helps with configuration files and XML to JSON in the interface world. For content pipelines, Markdown to HTML converts quickly and reliably.

For text files, the character encoding is crucial. Today UTF-8 is the standard. Anyone who exports with the wrong encoding sees typical garbage characters such as ä with umlauts. Caution when sending over email: many attachments are automatically Base64-encoded, which inflates the file by about a third and is a common reason why sent documents seem larger than locally.

Web image formats 2026: WebP and the rise of AVIF

For images on the internet, the situation has shifted in recent years. WebP has become the de facto standard for modern delivered photos and is supported by practically all current browsers, according to Can I Use around 96.8 % (Mar 2026). New: AVIF has also reached critical mass, browser support stands at over 95 % and the gap to WebP has shrunk to just over one and a half percentage points. The old advice that AVIF is risky is therefore no longer tenable in 2026.

FormatWebsite usage (W3Techs)Browser supportRole 2026
PNG75.5 %around 99 %reference for graphics, transparency
JPEG69.4 %around 100 %photos, compatibility, email
SVG67.7 %around 98 %vector graphics, logos, icons
WebP21.8 %96.8 %primary modern web format
GIF13.5 %around 99 %animation, often replaced
AVIF1.7 %95.4 %premium compression, growing
HEICnot listed14.6 %, Safari onlyApple ecosystem
JPEG XLunder 0.1 %0 %practically dead for the web

In terms of compression, AVIF is clearly superior to JPEG and also ahead of WebP. As a guide: lossy WebP is about 25 to 34 % smaller than JPEG at the same quality, and AVIF is reportedly around 20 % smaller than WebP again depending on the source. The catch: AVIF does not always win. With flat graphics, logos and screenshots, WebP or a good JPEG can be smaller and cleaner. The pragmatic recommendation from experts is therefore the HTML picture element, which provides AVIF for modern, WebP for mid-range and JPG for old browsers, usually the CMS generates these three variants automatically from one upload.

Which format for which purpose?

Practice translates into a clear checklist. Anyone who sticks to it will in the vast majority of cases have both the right quality and the smallest sensible file.

  • Send or print a photo: JPG, quality about 80 to 90 %
  • Place a photo on a website: WebP
  • Logo or graphic with transparency: SVG, otherwise PNG
  • Screenshot: PNG
  • Animation, small and modern: WebP (animated) or MP4 instead of GIF
  • Send a document as final: PDF
  • Document official or for archiving: PDF/A
  • Text for further editing: DOCX
  • Calculations and tables: XLSX
  • Data between systems: CSV, for web and API JSON
  • Logs, notes and code: TXT with UTF-8
  • Several files as one attachment: ZIP
  • Listen to music universally: MP3, 128 to 320 kbit/s
  • Share video universally: MP4 with H.264
  • Output an iPhone photo: export as JPG
  • B2B invoice in Germany: XRechnung or ZUGFeRD, no normal PDF

Anyone looking for a complete process from image selection to export will find a step-by-step guide in the optimize images for the web playbook. The web images in publishing show how photos and graphics are prepared cleanly for publication.

Email attachments: size limits and the safe corridor

The maximum attachment size depends on the provider and usually refers to the entire message, meaning all attachments together. The Base64 encoding is also decisive: it increases the actual transfer size by about a third. A 25 MB message therefore only allows about 18 MB of raw file data.

Letters and envelopes, collected with a cord, on wood

ProviderLimit per messageRaw data after Base64Recommendation
Gmail (private)25 MBapprox. 18 MBup to 15 MB
Outlook.com25 MBapprox. 18 MBup to 15 MB
Yahoo Mail25 MBapprox. 18 MBup to 15 MB
GMX FreeMail20 MBapprox. 15 MBup to 10 MB
WEB.DE FreeMail20 MBapprox. 15 MBup to 10 MB
T-Online32 MBapprox. 24 MBup to 20 MB
Corporate Exchange (default)approx. 10 MBapprox. 7.5 MBup to 7 MB

The values come from the official help pages of the providers (Sep 2026). Corporate mail servers hang at about 10 MB as the factory default according to many IT experts, although administrators can raise the value and Microsoft 365 allows 25 MB by default (2026). If an attachment exceeds the limit in Gmail, it is automatically removed and inserted as a Google Drive link.

This produces a robust practical value: around 10 MB per email gets through with almost all providers, including restrictive corporate servers, and leaves enough buffer for the Base64 inflation. Anyone sending large images should compress them first with the image compressor or slim down PDFs with the PDF tools. You bundle several files into a ZIP folder, keeping in mind that some mail servers and authority ports block ZIP attachments for security reasons.

Understanding and controlling file sizes

The biggest levers for file size are resolution and quality, not the format itself. A photo with 12 megapixels is always large, whether as JPG or WebP, compression only saves a part. Anyone who wants small files first reduces the pixels, then the quality. The file size converter converts the common units KB, MB and GB when values from bitrates are to be translated into understandable sizes.

Open hard drive in detail, platters visible

Audio: The size of an MP3 file follows the formula bitrate × duration ÷ 8. At 128 kbit/s that is around 0.94 MB per minute and about 56 MB per hour, at 320 kbit/s around 2.3 MB per minute.

BitrateKB/sMB per minuteMB per hourUse
64 kbit/s80.47approx. 28speech podcast
128 kbit/s160.94approx. 56standard MP3, podcast
192 kbit/s241.4approx. 84music
320 kbit/s402.3approx. 138MP3 maximum

Video: Here total bitrate × duration ÷ 8 applies. A video at 5 Mbit/s needs about 37.5 MB per minute and around 2.25 GB per hour. The bitrate depends strongly on the codec and resolution.

ZIP: Compression is lossless, but it only works where redundancy exists. Text and CSV lose 60 to 80 % of their size, office documents 20 to 50 %, already compressed formats such as JPG, MP3, MP4 or PDF almost nothing. Wrapping an MP4 saves little space and the ZIP envelope only makes the file more unwieldy.

Video and audio: container, codec and the licensing question

A common misunderstanding: MP4 is not a codec, but a container, meaning a packaging for video and audio tracks. The actual compression method, the codec, sits inside it, for example H.264, H.265 or AV1. This difference explains why an identically looking MP4 runs on one device and not on another.

CodecYearRoyalty-freeCompression vs H.264Browser supportWeb recommendation
H.264/AVC2003noreferencearound 100 %fallback
H.265/HEVC2013no35 to 50 % lessfragmentedconditional
AV12018yes55 to 65 % lessover 95 %preference
VVC/H.2662020noeven betterbarelyno

H.264 remains the workhorse codec and runs everywhere. H.265 offers better compression but suffers from a complex licensing and patent situation that increasingly pushes manufacturers to AV1. AV1 is fully royalty-free, saves around half to two thirds of the bitrate compared to H.264 at the same quality and now has hardware support in almost all modern devices (2026). VVC finally is irrelevant for the browser and remains reserved for broadcast and premium OTT.

Animations too: anyone sharing short clips should not rely on GIF. GIF stores every frame as its own color-reduced image without inter-frame estimation and therefore becomes huge. An MP4 or WebM can be ten to a hundred times smaller depending on the subject, as shown by a comparison of a 5-second recording in which an 8.4 MB GIF only weighs 211 KB as H.264 MP4 (2026).

Authorities and official submission: PDF/A and e-invoices

For documents that are officially submitted or permanently archived, PDF is the standard and PDF/A the safe choice. PDF/A is a standardized archive format according to ISO 19005 that embeds fonts and colors bindingly and thus ensures long-term, device-independent readability. For most archiving and submission purposes, PDF/A-2 is the common recommendation, PDF/A-4 has been built on PDF 2.0 since 2020 (2026).

Hand sorts documents with paper clips, close-up

Already compressed or scanned authority documents are best bundled with the PDF tools into one file, and you protect confidential documents with a password. Important for context: the studio-tools PDF toolset creates a normal PDF export, PDF/A is created in the respective original writing program, for example via the export dialog of Word or a PDF printer with an archive profile.

Since 1 January 2025, the obligation to receive e-invoices has applied to domestic B2B business, and the creation obligation comes in stages: from 2027 for larger and from 2028 for all companies. The recognized formats are XRechnung and ZUGFeRD, which both build on the European standard EN 16931. Requirements to authorities are stricter and XRechnung has been standard there for longer (2026). A normal PDF is not an e-invoice, even if it is sent along as evidence.

Frequently asked questions

Which image file has the smallest file size?
For photos on the web, WebP is the most compact, Google reports around 25 to 34 percent less than a comparable JPG at the same quality. For graphics with transparency, WebP or a cleanly optimized PNG wins. For animations, video instead of GIF is the best choice, an MP4 can be ten to a hundred times smaller depending on the subject. Important: the smallest file is not automatically the best, for print and archives JPG or PDF remains the safe choice.
Is WebP better than JPG and should I convert everything?
For websites yes: WebP offers clearly smaller files at the same visual quality and is now supported by more than 96 percent of browsers. For archiving, printing or when older software is involved, JPG remains the safe standard. A blanket conversion is not necessary, modern image workflows generate WebP on export in addition, without deleting the original JPG.
Can I convert a JPG back into lossless quality?
No. Converting JPG to PNG is technically possible, but the image data removed when saving the JPG does not come back, the file only becomes larger. The generation effect cannot be reversed. Anyone who wants to preserve quality always works from the best possible original, meaning the raw format or the uncompressed intermediate state.
Why is my converted file sometimes larger than before?
Typical causes are a lossless target, a JPG to PNG conversion inflates photos, a higher DPI when rendering, embedded metadata and fonts in PDF, and the Base64 encoding of email attachments which adds about 33 percent. So deliberately set target parameters such as resolution and quality on export instead of simply swapping the format.
How large may an email attachment be at most?
Privately, Gmail and Outlook.com allow 25 MB per entire message, Yahoo also 25 MB, GMX and WEB.DE 20 MB in the free version, T-Online 32 MB. Corporate mail servers often hang at around 10 MB. Since attachments become about 33 percent larger due to Base64 encoding, a safe target corridor of about 10 MB of raw file size per email is the robust rule of thumb.
Which format do authorities accept most safely?
PDF, and for archiving and submission purposes best PDF/A according to ISO 19005. It is device-independent, prints identically and is considered the official long-term standard. Editable formats such as DOCX should never be the official submission. For invoice submission, legislation has required e-invoices in XRechnung or ZUGFeRD since 2025 instead of a normal PDF.
What is the difference between MP4 and H.264?
MP4 is the container, meaning the packaging for video and audio tracks, subtitles and metadata. H.264 is a video codec, the actual compression method that can sit inside. An MP4 file can also be encoded with H.265 or AV1. That is why the same file extension does not mean the same playability, the player must support the codec.
Why does my iPhone save photos as HEIC and not JPG?
Since iOS 11 in 2017, HEIC is the standard because it takes up around half the file size at similar quality. For exchange with Windows and Android or for upload forms, however, HEIC is often problematic. In the iPhone photo settings you can set the transfer to automatic, or convert deliberately to JPG.
Do I lose quality when I zip a file?
No. ZIP works losslessly, the content is byte-identical afterwards. But ZIP barely compresses already compressed formats such as JPG, MP3, MP4 or PDF, where the savings are near zero. ZIP works mainly on text, CSV, office documents and uncompressed formats.

This handbook is a general guide and does not replace professional advice. Compression formats and browser shares change constantly, rely on current values for concrete projects. Authority requirements and the e-invoice obligation can shift with legislation changes, check deadlines and requirements in individual cases.

Sources & status of these figures

The figures in this handbook come from the named sources and were last checked on 12 September 2026. Market shares of formats, browser support and provider size limits change, so every current value carries a date. Experience values are marked as such.

  • W3Techs: distribution of image formats on the web, September 2026. w3techs.com
  • Can I Use: browser support for WebP, AVIF, HEIC and JPEG XL, March 2026. caniuse.com
  • Google: An image format for the Web (WebP study, 25 to 34 percent smaller than JPEG). developers.google.com
  • Gmail Help: attachment size limits, 25 MB private, Drive link on excess. support.google.com
  • Microsoft: sending limits in Outlook.com, 25 MB, OneDrive share up to 2 GB. support.microsoft.com
  • GMX Help: attachment limit FreeMail 20 MB, ProMail 50, TopMail 100. hilfe.gmx.net
  • WEB.DE Help: attachment limit FreeMail 20 MB, Club and MailPlus up to 100 MB. hilfe.web.de
  • Telekom hilft: maximum attachment size at T-Online 32 MB. telekomhilft.telekom.de
  • WiseStamp: default attachment limits on-premises Exchange around 10 MB. wisestamp.com
  • PDF Association: ISO 19005 PDF/A, versions 1 to 4 and levels. pdfa.org
  • Federal Ministry of Finance: e-invoice with XRechnung and ZUGFeRD, transition from 2025.
  • RFC 4180: Common Format and MIME Type for Comma-Separated Values (CSV). datatracker.ietf.org
  • Bitmovin: Video Developer Report, version 10, 2026. streaminglearningcenter.com
  • forasoft: Visual codec comparison H.264 vs H.265 vs AV1, May 2026. forasoft.com
  • web.dev: Replace animated GIFs with video for faster page loads. web.dev