MIME-Typen
Ein MIME-Typ — der Wert des Content-Type-Headers — ist, wie ein Server sagt, was eine Datei ist. Nichts vom Dateinamen erreicht den Browser, darum ist die Erweiterung ein Hinweis für Sie und der Typ ist die Tatsache für den Client. Bei einem Fehler wird eine Stil-Datei ignoriert, eine Schrift kann nicht geladen werden oder eine PDF wird heruntergeladen, statt sich zu öffnen.
Diese Seite listet die Erweiterung und den Typ auf, den das Nachschlag-Werkzeug dieser Website dafür zurückgibt, darum können die beiden niemals auseinandergehen. Wo mehrere Erweiterungen einen Typ teilen — jpg, jpeg und jpe oder yaml und yml — wird jede in einer eigenen Zeile aufgelistet, weil Sie diejenige nachschlagen, die Sie haben.
Zwei Regeln erklären die meisten Überraschungen unten. Ein Typ, der mit application/vnd. beginnt, ist eine Anmeldung des Anbieters, kein offener Standard, darum sind die Office-Typen so lang. Und ein Typ, den der Server nicht kennt, wird am besten als application/octet-stream versendet, was dem Browser sagt, dass er herunterladen soll, statt zu raten.
Web und Text
21text/* ist die Familie, die ein Browser anzeigt, statt herunterzuladen, und die einzige, wo ein Zeichensatz-Parameter wichtig ist — text/html; charset=utf-8.
| Erweiterung | MIME-Typ | Worum es geht |
|---|---|---|
| .html | text/html | HTML-Dokument |
| .htm | text/html | HTML-Dokument, kurze Erweiterung |
| .shtml | text/html | HTML mit Server-seitige Includes |
| .xhtml | application/xhtml+xml | XHTML-Dokument |
| .css | text/css | Stylesheet |
| .csv | text/csv | Komma-getrennte Werte |
| .txt | text/plain | Klartext |
| .md | text/markdown | Markdown-Quelle |
| .ics | text/calendar | Kalenderereignis |
| .xml | application/xml | XML-Dokument |
| .js | text/javascript | JavaScript |
| .mjs | text/javascript | JavaScript ES-Modul |
| .json | application/json | JSON-Daten |
| .jsonld | application/ld+json | JSON-LD strukturierte Daten |
| .webmanifest | application/manifest+json | Web-App-Manifest |
| .yaml | application/yaml | YAML-Dokument |
| .yml | application/yaml | YAML, kurze Erweiterung |
| .toml | application/toml | TOML-Konfiguration |
| .sql | application/sql | SQL-Skript |
| .sh | application/x-sh | Shell-Skript |
| .wasm | application/wasm | WebAssembly-Modul |
Dokumente
12Office-Typen sind lang, weil sie den Anbieter, Standard und Teil kodieren — vnd. bedeutet eine Anmeldung des Anbieters, nicht ein offenes Format.
| Erweiterung | MIME-Typ | Worum es geht |
|---|---|---|
| application/pdf | PDF-Dokument | |
| .rtf | application/rtf | Formatierten Text |
| .doc | application/msword | Word-Dokument, altes Binary |
| .docx | application/vnd.openxmlformats-officedocument.wordprocessingml.document | Word-Dokument |
| .xls | application/vnd.ms-excel | Excel-Arbeitsmappe, altes Binary |
| .xlsx | application/vnd.openxmlformats-officedocument.spreadsheetml.sheet | Excel-Arbeitsmappe |
| .ppt | application/vnd.ms-powerpoint | PowerPoint-Präsentation, altes Binary |
| .pptx | application/vnd.openxmlformats-officedocument.presentationml.presentation | PowerPoint-Präsentation |
| .odt | application/vnd.oasis.opendocument.text | OpenDocument Text |
| .ods | application/vnd.oasis.opendocument.spreadsheet | OpenDocument Tabelle |
| .odp | application/vnd.oasis.opendocument.presentation | OpenDocument Präsentation |
| .epub | application/epub+zip | EPUB E-Book |
Bilder
14Jeder Bildtyp ist von seinen ersten Bytes schnüffelbar, darum wird ein Browser ihn üblicherweise richtig rendern, selbst wenn der Server ihn falsch beschriftet hat. SVG ist die Ausnahme, die Sie niemals falsch beschriften sollten — es ist ein Dokument, das ein Skript tragen kann.
| Erweiterung | MIME-Typ | Worum es geht |
|---|---|---|
| .png | image/png | PNG-Bild |
| .jpg | image/jpeg | JPEG-Bild |
| .jpeg | image/jpeg | JPEG-Bild, lange Erweiterung |
| .jpe | image/jpeg | JPEG-Bild, seltene Erweiterung |
| .gif | image/gif | GIF-Bild |
| .webp | image/webp | WebP-Bild |
| .avif | image/avif | AVIF-Bild |
| .svg | image/svg+xml | SVG-Vektorbild |
| .bmp | image/bmp | Bitmap-Bild |
| .ico | image/vnd.microsoft.icon | Symbol-Datei |
| .tif | image/tiff | TIFF-Bild |
| .tiff | image/tiff | TIFF-Bild, lange Erweiterung |
| .heic | image/heic | HEIC-Bild |
| .heif | image/heif | HEIF-Bild |
Audio
11Container und Codec sind zwei verschiedene Fragen. audio/ogg sagt, wie die Datei verpackt ist; was darin sein kann, ist Vorbis, Opus oder FLAC.
| Erweiterung | MIME-Typ | Worum es geht |
|---|---|---|
| .mp3 | audio/mpeg | MP3-Audio |
| .wav | audio/wav | WAV-Audio |
| .ogg | audio/ogg | Ogg-Audio |
| .oga | audio/ogg | Ogg-Audio, explizite Erweiterung |
| .opus | audio/opus | Opus-Audio |
| .m4a | audio/mp4 | AAC-Audio in MP4-Container |
| .flac | audio/flac | FLAC verlustfreies Audio |
| .weba | audio/webm | WebM-Audio |
| .aac | audio/aac | Rohes AAC-Audio |
| .mid | audio/midi | MIDI-Sequenz |
| .midi | audio/midi | MIDI, lange Erweiterung |
Video
9Das Streamen eines Videos braucht mehr als nur den richtigen Typ — der Server muss auch auf Bereichsanfragen antworten, oder der Browser lädt die ganze Datei herunter, bevor sie abgespielt wird.
| Erweiterung | MIME-Typ | Worum es geht |
|---|---|---|
| .mp4 | video/mp4 | MP4-Video |
| .m4v | video/mp4 | MP4-Video, Apples Erweiterung |
| .webm | video/webm | WebM-Video |
| .ogv | video/ogg | Ogg-Video |
| .mov | video/quicktime | QuickTime-Video |
| .avi | video/x-msvideo | AVI-Video |
| .mkv | video/x-matroska | Matroska-Video |
| .wmv | video/x-ms-wmv | Windows Media Video |
| .3gp | video/3gpp | 3GPP Mobiles Video |
Schriften
5Die font/*-Familie wurde spät angemeldet; ältere Werkzeuge senden immer noch application/font-woff und application/x-font-ttf, die Browser akzeptieren, aber nicht für neue Sachen geschrieben werden sollten.
| Erweiterung | MIME-Typ | Worum es geht |
|---|---|---|
| .woff | font/woff | WOFF-Web-Schrift |
| .woff2 | font/woff2 | WOFF2-Web-Schrift |
| .ttf | font/ttf | TrueType-Schrift |
| .otf | font/otf | OpenType-Schrift |
| .eot | application/vnd.ms-fontobject | Embedded OpenType, nur Internet Explorer |
Archive und Binärdateien
12application/octet-stream ist die ehrliche Antwort, wenn nichts Besseres bekannt ist, und es ist auch das, was einen Download erzwingt, statt zu raten.
| Erweiterung | MIME-Typ | Worum es geht |
|---|---|---|
| .zip | application/zip | ZIP-Archiv |
| .gz | application/gzip | Gzip-Archiv |
| .tar | application/x-tar | Tar-Archiv |
| .7z | application/x-7z-compressed | 7-Zip-Archiv |
| .rar | application/vnd.rar | RAR-Archiv |
| .bz2 | application/x-bzip2 | Bzip2-Archiv |
| .iso | application/x-iso9660-image | Disk-Abbild |
| .bin | application/octet-stream | Unbekannte Binärdaten |
| .exe | application/x-msdownload | Windows-Anwendung |
| .apk | application/vnd.android.package-archive | Android-Paket |
| .deb | application/vnd.debian.binary-package | Debian-Paket |
| .swf | application/x-shockwave-flash | Flash-Film, längst veraltet |