Lotus 1-2-3 spreadsheet
application/vnd.lotus-1-2-3;version=4
Magic Bytes
Offset: 0
00 00 1A 00 02 10 04 00
The WK4 file format is a spreadsheet document created by Lotus Software and later maintained by IBM for the Lotus 1-2-3 suite. It was primarily used for organizing data, performing financial calculations, and generating business charts within Windows-based productivity environments. Now considered an obsolete legacy format, it remains relevant for digital archiving and is generally regarded as safe because it lacks the complex executable macro capabilities found in many contemporary spreadsheet formats.
Validation Code
How to validate .wk4 files in Python
Python
def is_wk4(file_path: str) -> bool:
"""Check if file is a valid WK4 by magic bytes."""
signature = bytes([0x00, 0x00, 0x1A, 0x00, 0x02, 0x10, 0x04, 0x00])
with open(file_path, "rb") as f:
return f.read(8) == signature
How to validate .wk4 files in Node.js
Node.js
function isWK4(buffer: Buffer): boolean {
const signature = Buffer.from([0x00, 0x00, 0x1A, 0x00, 0x02, 0x10, 0x04, 0x00]);
return buffer.subarray(0, 8).equals(signature);
}
Go
func IsWK4(data []byte) bool {
signature := []byte{0x00, 0x00, 0x1A, 0x00, 0x02, 0x10, 0x04, 0x00}
if len(data) < 8 {
return false
}
return bytes.Equal(data[:8], signature)
}
API Endpoint
GET
/api/v1/wk4
curl https://filesignature.org/api/v1/wk4