Web Open Font Format (.woff)
W3C StandardWeb Open Font Format (WOFF) is the historic first-generation open standard web font format endorsed by the W3C, wrapping standard TrueType or OpenType fonts with zlib compression and XML licensing metadata.
Inspect & Metadata
Operating systems and file analyzers identify WOFF files by inspecting the leading binary byte sequence:
Byte-Level Header Signature (Magic Bytes)
Operating systems and file analyzers identify WOFF files by inspecting the leading binary byte sequence:
HEX SIGNATURE (OFFSET 0):
77 4F 46 46ASCII REPRESENTATION: wOFF
Standardization: W3C Recommendation (2012)
Technical Specifications
| Container Architecture | 44-byte WOFF header followed by table directory, zlib-compressed table data, optional extended metadata, and private data |
| Compression | Deflate (zlib) compression applied to each individual font table |
| Byte Endianness | Big-Endian (SFNT standard) |
| Color Spaces | Inherited from underlying font tables |
| Channels & Structure | TrueType ('glyf') or PostScript ('CFF ') glyph outlines, metrics, and typographic features |
| Max Dimensions | Up to 65,535 glyphs per font file |
| Transparency | Inherited from underlying font format |
| Streaming & Progressive | Table-by-table decompression enables streaming font loading |
Technical Comparison Matrix: WOFF vs Competitors
| Technical Attribute | WOFF (Current) | WOFF2 | TTF | OTF |
|---|---|---|---|---|
| Compression Codec | Deflate (zlib) per table | Brotli with table preprocessing | Uncompressed SFNT | Uncompressed SFNT |
| Magic Signature | wOFF (0x77 0x4F 0x46 0x46) | wOF2 (0x77 0x4F 0x46 0x32) | 0x00 0x01 0x00 0x00 | OTTO (0x4F 0x54 0x54 0x4F) |
| Relative File Size | Often smaller than TTF; savings vary by font | Often smaller than TTF; savings vary by font | Baseline standard (100%) | Baseline standard (100%) |
| Target Environment | Legacy web browsers (IE9+, Safari 5+) | Support varies by browser. | Desktop operating systems | Desktop publishing & print |
Common Corruption Modes & Hex Recovery Guide
Browser console warning: 'Failed to decode downloaded font: OTS parsing error'.
Root Cause: Mismatch in declared uncompressed table length or damaged zlib stream.
Recovery: Re-compress font tables or convert to WOFF2 using File2File.app Font Converter.
Security Analysis & Parser Attack Vectors
Web browsers parse WOFF files downloaded from untrusted web domains using the OpenType Sanitizer (OTS) to block exploit payloads.
Known Attack Vectors
- Buffer over-read during zlib decompression of corrupt font table chunks.
- Mismatched table length fields triggering heap buffer overflows in font renderers.
- Denial of service through memory exhaustion during font table expansion.
Defensive Best Practices: Always sanitize downloaded WOFF files with OTS before passing to operating system font engines.
Historical Origins & Milestones
Key Advantages & Pros
- Can reduce web font file sizes compared with raw TTF or OTF files; the amount depends on the font and encoder.
- WOFF is supported by many browsers, including older versions; compatibility depends on browser version and platform.
- Includes an optional XML metadata block for font licensing, author credits, and foundry copyright information.
Technical Limitations & Cons
- Superseded in many web workflows by WOFF2, which uses Brotli compression and font table transforms; file-size savings vary.
- Cannot be installed directly into desktop operating systems (Windows/Mac) without conversion to TTF/OTF.
- Older zlib compression algorithm is less efficient than modern entropy encoders.
Interesting Technical Trivia
- The magic bytes for WOFF 1.0 are 'wOFF' (0x77 0x4F 0x46 0x46), while WOFF 2.0 uses 'wOF2'.
- Type foundries agreed to allow their fonts on the web only after WOFF was created, because its specialized container distinguished web fonts from piratable desktop fonts.
- WOFF was originally implemented in Firefox 3.6 in 2010 before becoming an official W3C recommendation.
Frequently Asked Technical Questions
What is the difference between WOFF and WOFF2?
WOFF uses zlib compression, while WOFF2 uses Brotli compression and font table transforms. The resulting file-size difference depends on the font and encoder.
How can I convert a WOFF font to TTF or OTF for desktop use?
You can convert WOFF files into installable desktop TTF or OTF fonts in seconds using File2File.app directly in your web browser.
Do I still need WOFF 1.0 on modern websites?
Current major browsers support WOFF2. A WOFF fallback may still be useful for older browsers or specific embedded environments.