Webviewer server annotations

WebViewer Version: 8.0.0
[WebViewer Server] server version: 1.5.6-gf198a7c

Do you have an issue with a specific file(s)?
Can you reproduce using one of our samples or online demos?
Are you using the WebViewer server?
Does the issue only happen on certain browsers?
Is your issue related to a front-end framework?
Maybe, I’m using react
Is your issue related to annotations?

Please give a brief summary of your issue:
Webviewer server annotations

Please describe your issue and provide steps to reproduce it:
Annotations are not received and not displayed while files are loaded by webviewer server, but if I will replace loading doc by webviewer server and just put doc url into initialDoc property - all works fine, and also if I remove webviewerServerURL property all works fine to.

Please provide a link to a minimal sample where the issue is reproducible:

const instance = await WebViewer(
            path: '/WebViewer/lib',
            fullAPI: true,
            licenseKey: license,
            enableAnnotations: true,
            preloadWorker: 'pdf',
            webviewerServerURL: pdfTronServerUrl,
            singleServerMode: true
          viewer.current as HTMLElement
   instance.UI.loadDocument(docUrl, {
        filename: fileName,
        customHeaders: {

Annotations were stored by this way:

  const handleGetFile = useCallback(async () => {
    const { documentViewer, annotationManager, SaveOptions } = instance.Core;
    const receivedDoc = documentViewer.getDocument();
    const xfdfString = await annotationManager.exportAnnotations();
    const options = {
      flags: SaveOptions.LINEARIZED,
      downloadType: 'pdf'
    const data = await receivedDoc.getFileData(options);
    const arr = new Uint8Array(data);
    const blob = new Blob([arr], { type: 'application/pdf' });
    const { closeElements } = instance.UI;
  }, [instance]);

Hello, I’m Ron, an automated tech support bot :robot:

While you wait for one of our customer support representatives to get back to you, please check out some of these documentation pages:


Hello Kostiantyn,

Welcome to the PDFTron Community Forum!

Checking out your code snippets, I noticed that after blob is created it is not used anywhere, if you upload that blob to the server, it will save the PDF with the annotation XFDF string.

We have a guide on merging imported/exported annotations here:

Specifically I would recommend this guide, as the code is very similar to what you are doing:

Best Regards,
Tyler Gordon
Web Development Support Engineer
PDFTron Systems, Inc.