Moodle document conversion: what unoconv and Google Drive each do for annotation
Teachers who grade in Moodle often need to annotate a student's Word document or slide deck directly in the grading view, and that annotation works on a PDF rendering of the submission. Moodle core ships two file converters for this job: one that uses unoconv on a server you run, and one that uses Google Drive. Both convert submitted files to PDF so the grader can mark them up, but they differ in where the file goes while the conversion happens. Before enabling either, confirm with your own team which converters your Moodle version exposes in its file converter settings, because the set of options is part of the code you deploy and should be checked on your exact release rather than assumed from older documentation.
The choice between the two is mainly a data-location decision. With the unoconv converter, the submitted file is handled by a conversion service on infrastructure your organization controls, so the document never leaves your network for this step. With the Google Drive converter, the file is uploaded to Google so Google can produce the PDF, which means the content is processed by a third party under that provider's terms and the Google Workspace configuration of your institution. The file converter source in the Moodle repository shows how each converter is implemented and is the natural next read for engineers who need to see the code path. Do not treat the two as interchangeable for coursework that contains personal data, assessment material or research records.
What you need before enabling document conversion
Document conversion depends on four things lining up: the Moodle version and server stack, a converter host that can run LibreOffice, a Google Cloud setup if you use the Drive path, and network rules that let the right processes reach the right services. Work through these cards before you change any converter setting, and confirm the exact package and API requirements in your own environment and the converter source.
Confirm your Moodle version and stack
Start by checking the Moodle version you run against its release notes, since server requirements change between releases. Moodle 5.1 requires 64-bit PHP 8.2 or later and PostgreSQL 15, MySQL 8.4, MariaDB 10.11 or SQL Server 2017 or later, and from 5.1 the web server document root must point to the public directory. Record your PHP and database versions now, because the converter settings you choose sit on top of that stack.
Plan a converter host with LibreOffice
The unoconv path needs a server with a LibreOffice installation that unoconv can drive, and that host must be reachable by both the web and cron processes that trigger conversions. Decide whether it is the Moodle server itself or a separate host, and confirm the required packages for your operating system before you install anything. A separate host keeps document processing away from the main application, but it adds a network hop and one more system to patch.
Confirm unoconv settings in Moodle
Check how the converter is configured in your Moodle site before you rely on it for teacher annotation. The unoconv converter reads a path to the unoconv executable and the converter must be enabled in the file converter settings. Test a sample conversion from the same account type that teachers use, and keep the converter source on hand so you can match your configuration to the code that actually runs in your version.
Converter sourceSet up a Google Cloud project for Drive
The Google Drive converter needs a Google Cloud project with the Drive API enabled, an OAuth consent screen and client credentials that Moodle uses to create and convert files. Your Google Workspace administrator may need to approve the app for your domain, and the consent scope should match what Moodle requests. Confirm the current Google API and consent requirements in the Google Cloud console for your account, because those screens change over time.
Understand the Drive privacy trade-off
The Google Drive path sends submitted documents to Google to be converted, so the file contents leave your infrastructure. Review whether your data protection terms, student records rules and Workspace data settings allow that transfer before you enable it. The unoconv path keeps conversion inside servers you control, which is why many institutions choose it for sensitive coursework.
Open only the required network paths
Map which connections each path needs before you change firewall rules. The web and cron processes must reach the converter host, and the Drive path needs outbound access from Moodle to Google endpoints, which your proxy or egress rules may block. Keep the rules narrow, test from the same network segment as Moodle, and document each opened path so a security review can trace it back to a purpose.
Choosing unoconv or the Google Drive converter
The unoconv path runs the conversion on a host you manage. Moodle core ships a converter that calls unoconv, which drives LibreOffice to turn Office documents into PDF. Student submissions are converted inside your network and are not sent to a third-party service for this step, which keeps the converted copies under your own storage, backup and access controls. The cost is that someone must install, patch and monitor the converter host and keep it matched to the LibreOffice version it depends on.
- Data residency: the source file and the PDF stay in the infrastructure you choose, which simplifies answers to residency and data processing questions.
- Copies held: you control every temporary and cached copy, including where converter output is written and how long it persists.
- Operating cost: the host, its patching and its capacity are your costs, recurring each year, and they scale with submission volume at peak deadlines.
- Maintenance: someone owns the LibreOffice and unoconv versions, font packages and the conversion service, and must test them after Moodle upgrades.
- Failure ownership: when conversions fail, your team diagnoses the host, not an external provider.
Before committing, ask your Moodle hosting team who will own the converter host and how its updates are tested against your Moodle release.
The Google Drive path sends the file to Google, which converts it and returns a PDF for annotation. Moodle core includes this converter, and it depends on a Google account and the Google services behind it. You remove the converter host from your estate, but the file itself leaves your infrastructure for this step, so your privacy review must cover Google as a processor for that data.
- Data residency: the conversion happens in Google's services, so you must confirm where your Workspace data is stored and processed under your agreement with Google.
- Copies held: Google holds the converted document as part of its service, and your team cannot inspect or purge intermediate copies directly.
- Operating cost: there is no converter host to run, but the Google Workspace licences and the account administration that the integration needs are recurring costs you must budget.
- Account dependence: conversions stop if the service account, its consent or its admin policies change, or if Google restricts the service for your domain.
- Admin consent: the integration requires Google OAuth setup in your Workspace admin console, which has to be reviewed each time the connection changes.
Confirm with your Google Workspace administrator which services are enabled for students, since policy changes there can break conversions without any change in Moodle.
A school that already runs Google Workspace for Education often finds the Drive path fits its existing contracts, identity model and administrators. Students already sign in with Google accounts and already store documents in Google services, so the conversion adds little new data exposure beyond what the institution has already reviewed. This reasoning holds only if the privacy review for Workspace has been completed and the institution accepts Google as a processor for the assignment files Moodle sends.
- Existing estate: the Google OAuth connection, Drive repository and conversion share one administrative model you already run.
- Low host burden: a small team with no infrastructure capacity avoids running a converter host and its patch cycle.
- Policy fit: if your Workspace policies already govern student documents, the conversion sits inside those rules.
- Trade-off: teams that must keep all student work inside their own network, or that run Moodle without Google sign-in, usually have a weaker case for this path.
- Exit planning: if you later move off Google, the converter setting and dependent annotations need a migration step.
Check with your data protection lead whether the Workspace agreement covers assignment annotation files, not only email and storage.
How to configure unoconv on your server, step by step
This sequence takes a Moodle site from no document conversion to a working unoconv setup that turns submitted Word, PowerPoint and similar files into PDFs teachers can annotate. Each step ends with a check you can run before moving on.
Confirm the converter server and its runtime
Your systems administrator installs the unoconv tool and the LibreOffice components it drives on the server that will run conversions, then confirms the install from the command line by converting a sample document to PDF outside Moodle. Confirm the package versions with your platform team and check them against the Moodle release you run. The step is done when the sample file opens as a valid PDF on that server.
Make the web and cron user able to run the converter
Identify the operating system account that runs the web server and the Moodle cron job, then confirm that account can execute the converter and read and write Moodle's temporary and file data directories. Run the same sample conversion as that account, not as your administrator login, because permissions often differ between the two. The step is done when the conversion succeeds under the web or cron account and the output lands in a location Moodle can read.
Point Moodle's converter settings at unoconv
In Moodle's site administration, open the file converter settings and set the unoconv path to the executable you verified in the first step. Leave the Google Drive converter disabled for now so that a single converter handles requests and failures are easy to trace. The step is done when the settings save without error and the converter status page reports unoconv as available.
Enable conversion for the required file types
Decide which source formats teachers need annotated, typically Word, PowerPoint and Excel files submitted to assignments, and enable conversion to PDF for those types only in the file converter configuration. Keep the list short so that you can test each type and so that unexpected uploads are not sent through the converter. The step is done when the enabled types are recorded in your change log and match the list teachers gave you.
Run a test conversion from site administration
Use the file converter test in site administration, or submit a test file to an assignment that uses annotation, and watch the conversion status for that file. Check that a PDF is produced and that the annotation view opens it in the grading interface. The step is done when the test file converts to PDF and the status shows the conversion as complete rather than pending or failed.
Check cron and the conversion queue
Confirm that Moodle's scheduled tasks run on schedule, because queued conversions are processed through the task system, and check that no conversion stays in a pending state after the next task run. Review the site logs and the server's process output for errors tied to the converter. The step is done when a queued conversion completes after one scheduled run and the logs show no repeated converter errors.
Document the setup and the failure path
Record the converter path, the service account, the enabled file types, the cron schedule and the test results in your operations runbook. Note who receives alerts when conversions fail and where teachers should report a file that will not annotate. The step is done when the runbook is reviewed by the people who will support the site and each step above has a recorded result.
Which file types, users and data each converter touches
This table maps what each converter receives, who sees the annotated PDF and where copies may sit during conversion. Read the unoconv column as data that stays on your server, and the Google Drive column as data that leaves it. Items marked as to verify depend on your Moodle version and local configuration, so confirm them in a test course before rollout.
| Element | unoconv on your server | Google Drive converter |
|---|---|---|
| Source file types | Office and other document formats that the local LibreOffice-based converter can open; confirm the supported list for your version | Document types that Google Drive can convert to PDF; confirm the supported list with Google |
| Converted output | A PDF generated on the Moodle server and stored as a Moodle file for annotation | A PDF created by Google Drive and returned to Moodle for annotation |
| Where the file is processed | Your own server or container, inside your network boundary | Google infrastructure, outside your servers |
| Temporary copies | Written to Moodle's temporary or file storage on your server during conversion; confirm the exact paths and cleanup behavior | Uploaded to a Google Drive account during conversion; confirm whether and how Google retains copies |
| User and course context | Conversion runs in the context of the submitting student's assignment; the teacher and student roles see the annotated PDF | Conversion runs through the Google account linked to Moodle; confirm which account is used for each user |
| Who receives the file | Only your Moodle server and the systems you operate | Google receives the submitted document, so review this against your data processing terms |
| Grader and student access | Graders see the annotated PDF in the assignment; students see their own submission and feedback, subject to assignment settings | Same grader and student views, but the source file has already passed through Google; confirm access rules for shared Drive files |
| Items to verify | Converter binary version, LibreOffice dependency and file permissions for the Moodle data directory | Google Workspace admin consent, OAuth scopes and whether the Drive file is kept after conversion |
Privacy trade-offs when student files leave your server
The core question is where a student's submitted file goes during conversion. With the unoconv converter, Moodle hands the file to a LibreOffice-based process running on a server you operate, so the document stays inside infrastructure you control. With the Google Drive converter, Moodle uploads the file to a third-party service, which converts it and returns the PDF. That upload is a disclosure to a processor you do not run, and the data protection owner needs to decide whether that disclosure is acceptable for each class of file, including files that contain special category or identifying content. Confirm which Google service terms and data processing terms your institution holds before the decision is recorded.
Retention is the detail teams most often miss. Converted and intermediate files are written to Moodle's file storage and temporary directories, and a failed or abandoned conversion can leave copies behind. On your own server, check how long those temporary files persist, who can read the directories, and whether your cleanup tasks remove them. On the Google Drive path, ask the vendor and your Google Workspace administrator how the converted copy is stored, how long it is kept on their side, and whether deletion in Moodle also removes the copy held in the Drive account used for conversion. Write the answers into the decision record rather than assuming them.
Backup scope changes the picture as well. A Moodle backup of the file area includes whatever files Moodle holds at that moment, so the answer to "what is in our backups" depends on the converter. Your data protection owner should also review the institution's processing terms with each converter provider, the data categories involved, and the lawful basis or policy text that covers the processing. Record the chosen converter, the reasons, the retention and backup behaviour, and the approver in a documented decision that is reviewed when the Moodle version or the Google Workspace configuration changes. Do not treat this as a legal conclusion: the decision belongs to your institution and its advisers.
Hardening the converter and protecting converted files
A document converter receives student submissions and writes copies of them to disk, so it inherits the sensitivity of everything students upload. The cards below cover where the converter runs, who can reach it, how files are stored while they are converted and how the Google path is authorized. Confirm each control against your own information security policy before you rely on it.
Isolate the converter host
Run unoconv and its LibreOffice backend on a dedicated host or container that holds no other Moodle role and no database credentials. Conversion parses untrusted files written by students, so a flaw in the office suite should not expose the Moodle database or your wider network. Check that the host can reach only what it needs, such as the Moodle web server that calls it, and that outbound connections are blocked by default.
Restrict who can reach the converter
Limit the network path to the converter to the Moodle application servers, using firewall rules or a private network segment. Nothing else, including user workstations, should be able to submit files to it directly. Confirm which listening port and protocol your deployment uses and whether the service requires any authentication of its own.
Limit permissions on working directories
The converter reads input and writes PDF output in directories that the web server and the conversion process can access. Give these directories the narrowest owner and mode that lets the process work, and keep them out of the public web root. Confirm that converted PDFs are not reachable by URL except through Moodle's own access checks, because a directly served file bypasses course enrolment and role rules.
Keep converter software patched
Patch LibreOffice, unoconv and the operating system packages beneath them on a schedule you can prove. Office document parsers have a history of security fixes, so a converter that falls behind is a known weakness, not a neutral one. Record the installed versions in your configuration management, and test a conversion of a sample file after each update before it reaches production.
Review Google scopes and admin consent
For the Google Drive path, review which OAuth scopes the Google service requests and which Workspace administrator approves them. Grant only the Drive access the converter needs, and record who approved the access and when. Confirm with your Google Workspace administrator whether files are created in a shared account or in each user's own Drive, since that determines who can later see the converted copies.
Clean up temporary and converted files
Decide how long converted PDFs and intermediate files remain on disk, and run a scheduled job that deletes them after that period. Confirm with your data protection owner whether the retention period matches your policy, and whether backups hold copies that also need expiry. Test that the cleanup job removes files without disturbing active submissions.
Why document conversions fail and how to fix them
This table lists the failures teams most often hit when annotation PDFs do not generate, with the likely cause and fix for each converter path. Use it as a first-pass checklist, then confirm the exact messages in the Moodle logs and in the converter's own output before changing settings.
| Failure | Likely cause | Fix |
|---|---|---|
| Converter not reachable | Moodle cannot reach the unoconv listener or service on its configured host and port, often because it is bound to localhost or a firewall blocks it | Confirm the converter address in Moodle's file converter settings, make it reachable from the web and cron processes, and test the connection from the Moodle host |
| Cron-run conversions fail only | The cron user lacks access to the converter, or the converter service runs under a different account than the web server | Run the conversion task as the same user that can reach the converter, then check the scheduled task log for the failing run |
| Unsupported or corrupt source file | The file type is not handled by the converter, or the upload is damaged or password protected | Open the original file locally, re-save it in a standard format, and confirm the file type is on the converter's supported list |
| Missing fonts or libraries | The converter host lacks fonts used in the document or libraries LibreOffice needs, so layout or export fails | Install the fonts and packages the converter reports as missing, then retest with a sample document that uses the same fonts |
| Timeouts on large files | Long documents, embedded images or heavy spreadsheets exceed the time the conversion is allowed to run | Raise the allowed conversion time within the converter and web server limits, and ask teachers to split or compress very large submissions |
| Permission errors on temporary directories | The account running the converter cannot write to the temporary or working directory | Grant write access to the converter's temporary path for the service account only, and confirm the path matches the one in the converter output |
| Google consent or quota errors on the Drive path | The Google account or Workspace app has not granted the required access, or the project has hit an API limit | Recheck the OAuth consent and API configuration in Google Cloud, confirm the Drive service is enabled, and review quota usage in the Google console |
| Where to look first | Failures appear in different places depending on the converter and the step that broke | Check the Moodle site logs and the scheduled task log for the conversion event, then the converter's own output or service log for the underlying error |
Questions buyers ask before setting up document conversion
Does unoconv or Google Drive conversion cost more to run?
Neither converter carries a licence fee from Moodle, so the cost comes from the work around it. With unoconv, you pay for server capacity that runs LibreOffice conversions, the administrator time to install and patch that software, and the time to diagnose failed jobs. With the Google Drive converter, the main costs are administrator time to set up Google Cloud access and the review of what leaves your network. Ask any partner to split a quote into one-time setup and recurring patching and support, so you can compare the two options on the same basis.
How long does a basic document conversion setup take?
The duration depends on scope: whether you run unoconv on an existing Moodle server or a separate host, whether you use the Google Drive converter, how many Moodle sites share the setup, and how much testing your privacy review requires. A basic unoconv setup on a server you already administer is mainly installation, configuration and a test submission. A Google Drive setup adds Google Workspace administration and consent steps. Ask for a written timeline tied to these items rather than a single number.
What does the school need to provide before setup starts?
For unoconv, you need shell access or a deployment pipeline for the host that will run the converter, a LibreOffice installation that matches your operating system policy, and a decision about where that host sits on your network. For the Google Drive converter, you need a Google Workspace administrator who can review and approve the required access, and a decision about which courses and users may send files to Google. Both routes need a named owner for privacy questions and an agreed test set of sample submissions.
Can our internal team run document conversion alone?
Yes, if your team already runs Moodle and a Linux server, and has someone comfortable with PHP-based applications, command-line tools and log analysis. The skills that are easiest to underestimate are converter patching, file permission problems, timeouts on large documents, and explaining to teachers why a file did not convert. A partner can help with the first build and a runbook, after which your team carries the routine work. Confirm the skills in your own team before deciding, because the answer depends on your staff, not on the software.
What are the privacy trade-offs between unoconv and Google Drive?
With unoconv, submitted files are converted on a server you control, so the file content stays inside your infrastructure. With the Google Drive converter, Moodle sends the file to Google to be converted, so the content leaves your environment and is subject to Google's terms for the account used. Your privacy review should cover student data in submissions, retention of converted copies, and whether the file types you accept contain personal information. Check the current Moodle converter code in the Moodle GitHub repository before you finalise the decision.
Who maintains the converter after go-live?
Your team, or a partner you retain, maintains the converter after go-live. With unoconv, that includes patching LibreOffice and the operating system, watching Moodle upgrades for changes to converter behaviour, and monitoring the host. With the Google Drive converter, you still own the Google Cloud project and consent settings, and you must check them when Google Workspace policies or Moodle versions change. Agree who receives alerts, who approves changes, and how often the configuration is reviewed.
What should we check when a conversion fails?
Start with the Moodle logs and the converter's own output, then reproduce the failure with the same file and the same user role. Common causes include an unsupported or corrupted source file, a converter process that cannot start or finish, missing fonts or permissions on the conversion host, and a Google Drive authorisation that has expired or been revoked. Record which file types fail so you can set expectations with teachers. If the failure follows a Moodle upgrade, check the release notes for the version you are moving to.
Does DeployOpen set up document conversion for us?
DeployOpen implements Moodle in infrastructure you control, and document conversion is part of that work when it is included in the written scope. We plan the converter choice with your privacy and IT owners, set up the chosen route, test it with your sample submissions, and document the operating steps. Scope, deliverables and timelines are agreed in writing before work starts, and a quote follows from that scope. Ongoing patching and support are available as retainers.
How DeployOpen scopes and delivers document conversion
DeployOpen plans and implements Moodle document conversion inside infrastructure you control, so teachers can annotate PDF submissions. The work starts with a written scope that compares the unoconv and Google Drive converters against your privacy requirements, then builds, tests and documents the chosen setup for your team to run.
How we scope
- Engagements are fixed-scope, with the converter choice, deliverables and timeline agreed in writing before work starts.
- We record which file types teachers submit and whether submissions may leave your network for Google Drive conversion.
- We confirm the Moodle version, web server, PHP and operating system so the unoconv setup matches your environment.
- We ask you to confirm the Google Workspace admin consent position if the Google Drive converter is in scope.
How we build
- We install and configure the chosen converter on your server, or enable the Google Drive converter with your admin consent.
- We test conversion of representative Word, PowerPoint and spreadsheet submissions into PDF before annotation is enabled.
- We set file size and timeout handling so failed conversions are logged and reported rather than silently dropped.
- We document the converter settings, dependencies and the test results so changes can be reviewed later.
How we hand over
- You receive a written configuration record covering converter settings, server packages, and the privacy trade-off you chose.
- We walk your administrators through the troubleshooting steps for common conversion failures and where logs are kept.
- We provide a runbook that explains how to repeat conversion tests after Moodle or server upgrades.
- Handover includes a retest of annotation on sample assignments so your team can confirm the setup works end to end.
How we support
- Ongoing support, upgrades and continuous testing are available as retainers after handover.
- A retainer can cover converter updates, re-testing after Moodle point releases and review of new conversion errors.
- We can help your team confirm converter behavior after a change to the web server or document root.
- Support scope, response arrangements and fees are set in writing, and we provide a quote from the agreed scope.

