A PDF describes itself in two places: the document information dictionary, a small dictionary of text fields named by the trailer, and an XMP metadata stream, an XML packet named by the catalog. PDF 1.5 to 1.7 files usually have both, kept in step. PDF 2.0 deprecates the information dictionary, apart from its two dates, and makes XMP the place for metadata.
The document information dictionary
The trailer’s Info points at it. Its values are
text strings,
except the dates and Trapped.
| Key | Since | Meaning | In PDF 2.0 |
|---|---|---|---|
Title | 1.1 | The title | deprecated |
Author | 1.0 | The person who made it | deprecated |
Subject | 1.1 | What it is about | deprecated |
Keywords | 1.1 | Keywords | deprecated |
Creator | 1.0 | The program the original document was made in, such as a word processor | deprecated |
Producer | 1.0 | The program that turned it into PDF | deprecated |
CreationDate | 1.0 | When it was made, a date | current |
ModDate | 1.1 | When it was last changed | current |
Trapped | 1.3 | True, False or Unknown (default): whether trapping for printing has been done | deprecated |
| any other | 1.1 | Writers may add their own keys, as text strings | deprecated |
The trailer must have Info when the catalog has PieceInfo,
whose private data is dated against ModDate. A PDF 2.0 file may leave
Info out altogether.
11 0 obj
<< /Title (Annual report)
/Author (A. Writer)
/Producer (Example PDF Library 3.2)
/CreationDate (D:20260214123151Z)
/ModDate (D:20260301090000Z) >>
endobj
XMP metadata streams
A metadata stream, from PDF 1.4, is a stream with Type Metadata and
Subtype XML whose data is an XMP packet (ISO 16684-1), XML in RDF form,
in UTF-8. The catalog’s Metadata holds the document’s. It is often left
uncompressed and, in an encrypted file, unencrypted (with
EncryptMetadata false), so that programs that do not read PDF can still
find it by scanning for the packet.
<?xpacket begin="" id="W5M0MpCehiHzreSzNTczkc9d"?>
<x:xmpmeta xmlns:x="adobe:ns:meta/">
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about=""
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:xmp="http://ns.adobe.com/xap/1.0/"
xmlns:pdf="http://ns.adobe.com/pdf/1.3/"
xmlns:xmpMM="http://ns.adobe.com/xap/1.0/mm/">
<dc:title><rdf:Alt><rdf:li xml:lang="x-default">Annual report</rdf:li></rdf:Alt></dc:title>
<dc:creator><rdf:Seq><rdf:li>A. Writer</rdf:li></rdf:Seq></dc:creator>
<dc:format>application/pdf</dc:format>
<xmp:CreateDate>2026-02-14T12:31:51Z</xmp:CreateDate>
<xmp:ModifyDate>2026-03-01T09:00:00Z</xmp:ModifyDate>
<pdf:Producer>Example PDF Library 3.2</pdf:Producer>
<xmpMM:DocumentID>uuid:…</xmpMM:DocumentID>
</rdf:Description>
</rdf:RDF>
</x:xmpmeta>
<?xpacket end="w"?>
The xpacket lines wrap the packet: begin holds a byte
order mark, the id is fixed, and end="w" says the packet may be
edited in place. Writers pad the packet with spaces before the end line so that it can
grow without moving bytes.
| Information dictionary | XMP property |
|---|---|
Title | dc:title (a language alternative) |
Author | dc:creator (an ordered list) |
Subject | dc:description |
Keywords | pdf:Keywords |
Creator | xmp:CreatorTool |
Producer | pdf:Producer |
CreationDate | xmp:CreateDate |
ModDate | xmp:ModifyDate |
Trapped | pdf:Trapped |
Other properties often seen: xmp:MetadataDate,
xmpMM:DocumentID and xmpMM:InstanceID (identifiers like the
trailer’s ID), pdf:PDFVersion,
pdfaid:part and pdfaid:conformance (which PDF/A part and
level the file claims, in http://www.aiim.org/pdfa/ns/id/),
pdfuaid:part for PDF/UA, and pdfx: and pdfxid:
properties for PDF/X. PDF/A requires the XMP and the information dictionary to agree.
Metadata on other objects
Any stream or dictionary that stands for a part of the document can carry its own
Metadata stream from PDF 1.4: pages, images, form XObjects, fonts and
their embedded programs, ICC profiles, structure elements and, from PDF 2.0, threads.
An image placed from a photo library often keeps its camera and rights data this way.
The PieceInfo dictionaries of pages, forms and the catalog hold a
different thing: private data of the program that made the object, keyed by its name,
with LastModified dates.
Metadata in PDF 2.0
PDF 2.0 deprecates every key of the information dictionary except
CreationDate and ModDate. The title, author and the rest
belong in the catalog’s XMP stream. Readers still meet many files with only an
information dictionary, so they read both. A file written for older readers keeps
both, with the same values.
Where the two disagree, the cause is usually a program that changed one and not the
other, such as a tool that edited the title in the information dictionary without
touching the XMP. Comparing ModDate with xmp:MetadataDate
or xmp:ModifyDate shows which was changed later.