The text of comments is in word/comments.xml, reached by the main
document’s comments relationship. The main text says only where each comment
is attached.
Anchors in the text
<w:p>
<w:commentRangeStart w:id="3"/>
<w:r><w:t>the commented words</w:t></w:r>
<w:commentRangeEnd w:id="3"/>
<w:r>
<w:rPr><w:rStyle w:val="CommentReference"/></w:rPr>
<w:commentReference w:id="3"/>
</w:r>
</w:p>
The range can cover several paragraphs, or be absent, leaving just the reference.
The comments part
<w:comments xmlns:w="…">
<w:comment w:id="3" w:author="Ada Example" w:initials="AE" w:date="2024-05-17T13:45:00Z">
<w:p>
<w:pPr><w:pStyle w:val="CommentText"/></w:pPr>
<w:r><w:rPr><w:rStyle w:val="CommentReference"/></w:rPr><w:annotationRef/></w:r>
<w:r><w:t>Could this be shorter?</w:t></w:r>
</w:p>
</w:comment>
</w:comments>
| Attribute | Meaning |
|---|---|
w:id | What the anchors in the text name. |
w:author, w:initials | Who wrote it: free text. |
w:date | When, as an ISO 8601 date and time. |
Authors’ names in comments, and those in tracked changes, stay in the file until they are removed.
Replies and resolved comments
The base format has no threads. Later versions of Word added further parts, tied to the
comments by the w14:paraId on each comment’s last paragraph:
| Part | What it adds |
|---|---|
word/commentsExtended.xml | One w15:commentEx for each comment: w15:paraId, w15:paraIdParent for a reply, and w15:done, which is 1 when the comment is resolved. |
word/commentsIds.xml | Durable IDs for comments. |
word/commentsExtensible.xml | Further details such as the time in UTC. |
word/people.xml | The authors: w15:person with w15:author and a presence record. |