Test files › Office documents › presentation.pptx
Sample PPTX file (presentation)
PowerPoint presentation with a slide master, layout and one titled slide.
↓ Download presentation.pptx| Filename | presentation.pptx |
| Format | PPTX |
| Size | 3.7 KB (3,790 bytes) |
| MIME type | application/vnd.openxmlformats-officedocument.presentationml.presentation |
| SHA-256 | 918c7c135ed89f8b0f662d1ead1bfeb7c5b75a94f2e5e6ca4d4a4aa347a6c35f |
What this file catchesA minimal but valid PPTX built from source as a ZIP of XML parts. Opens in the corresponding application; use it to exercise upload, parsing and preview without shipping a real document. PPTX is the strictest of the three - it needs a slide master and layout - so it catches thumbnailers that assume every OOXML file is flat.
Handle it in code
Each snippet below was run against this exact file with Python 3.14.4 and Node 24.15.0 when this page was built, and the output shown is what it printed.
Python
Check for macros before accepting or opening an Office upload. Modern files are ZIPs: VBA lives in vbaProject.bin (Microsoft) or a Basic folder (OpenDocument). Legacy .xls/.doc files are OLE2 containers that need a dedicated parser, such as oletools, to see inside.
import zipfile
OLE2 = bytes.fromhex("d0cf11e0a1b11ae1")
with open("presentation.pptx", "rb") as f:
magic = f.read(8)
if magic == OLE2:
print("legacy OLE2 file (.xls, .doc, .ppt, .msg): may carry VBA; inspect it with an OLE parser")
elif not zipfile.is_zipfile("presentation.pptx"):
print("not an Office file")
else:
with zipfile.ZipFile("presentation.pptx") as z:
names = z.namelist()
types = z.read("[Content_Types].xml").decode() if "[Content_Types].xml" in names else ""
macros = [n for n in names if n.lower().endswith("vbaproject.bin") or n.startswith(("Basic/", "Scripts/"))]
if macros or "macroEnabled" in types:
print("contains macros:", ", ".join(macros) or "declared in [Content_Types].xml")
else:
print(f"no macro parts among {len(names)} entries")Run against this file, it prints: no macro parts among 10 entries
Related guides and tools
Download & verify
curl -fsSL -o "presentation.pptx" "https://files.hexaqa.com/office/presentation.pptx"
curl -fsSL "https://files.hexaqa.com/office/presentation.pptx" | sha256sum
# expect: 918c7c135ed89f8b0f662d1ead1bfeb7c5b75a94f2e5e6ca4d4a4aa347a6c35f