OnlyOffice Issues
Fix documents that do not open, do not save, or keep auto-saving.
Fix documents that do not open, do not save, or keep auto-saving.
Editor Not Loading
Configuration Missing
Check:
- The Document Server URL and secret are saved in Settings → Administration → Integrations
BACKEND_URLis set in.env
Solutions:
- Save the OnlyOffice settings (first user only)
- Set
BACKEND_URLin.envand restart - Open the Document Server URL in a browser to check it answers
File Not Opening
Check:
- The file type is supported: Word, Excel and PowerPoint formats (
.docx,.doc,.xlsx,.xls,.csv,.pptx,.pptand their macro and template variants), OpenDocument (.odt,.ods,.odp) and.pdf - The Document Server is running
- The file content matches its extension
Solutions:
- A sub-user needs the Download permission to open documents
- A
.txtfile renamed to.docxdoes not open; see the next section
MIME Type Mismatch
Error: "Cannot open file: type mismatch (expected .docx format)"
Cause:
The file content does not match its extension, usually because the file was renamed to another type.
Solution: Rename the file back to its real extension, or save it in the right format and upload it again.
Callback Issues
Callback Not Working
Check:
BACKEND_URLis the address the Document Server uses to reach TMA Cloud- From the Document Server host,
curl $BACKEND_URL/healthanswers - No firewall blocks the Document Server from TMA Cloud
Edits Not Saved
When the Document Server reports a saved document, the server downloads it from the URL in the callback. It refuses some URLs and logs why:
[ONLYOFFICE] Blocked save URL outside the document server: the URL points to a private or internal IP address that is not the Document Server's own host. Set Document Server URL in Settings → Administration → Integrations → OnlyOffice to the address the Document Server uses in its download links.[ONLYOFFICE] Callback errorwithresolves only to internal addresses: the URL's hostname resolves to a private or internal address. Only the configured Document Server host may do that, so use that host name in Document Server URL.[ONLYOFFICE] Callback errorwith a timeout: the Document Server stopped sending the file for a minute. Check the network between the two servers.
Auto-Save Issues
Changes Not Saving Until Close
Expected behavior: Documents save to storage every five minutes by default while being edited.
Check:
- The background worker is running:
docker compose ps worker, ortma-server workeroutside Docker - The
job_schedulestable has a row namedonlyoffice:<document key> - Callback logs show status 6 with
forcesavetype: 0
If no schedule appears:
- Check app logs for
[ONLYOFFICE-AUTOSAVE] Failed to schedule document - Verify PostgreSQL is reachable from the app
- Open the document again after resolving the queue error
If force-save jobs fail:
- Check the OnlyOffice URL is correct and reachable from the worker
- If OnlyOffice uses HTTPS with a self-signed certificate, set
ONLYOFFICE_REJECT_UNAUTHORIZED=falseso the app accepts it when it downloads saved documents, or give the Document Server a trusted certificate - Check the Document Server container logs
If forcesave commands return non-200:
- Status 403: JWT secret mismatch between backend and OnlyOffice server
- Status 404 on both
/commandand/coauthoring/CommandService.ashx: The proxy is not exposing the command service - Check worker logs and failed jobs in the
onlyoffice-forcesavequeue
Auto-Save Running After Document Closed
Cause: Callback with status 2 or 4 was not received, so the document schedule was not removed. A later force-save response reporting that the document is closed also removes it.
Check:
- OnlyOffice server can reach the callback URL (
BACKEND_URL) - Callback endpoint returns
{ "error": 0 }(required for OnlyOffice to stop retrying) - No network/firewall issues between OnlyOffice container and backend
Only Manual Saves (Ctrl+S) Work
Cause: The auto-save service is not sending forcesave commands, or they are being rejected.
Check:
- Failed jobs in the
onlyoffice-forcesavequeue and worker logs - OnlyOffice JWT secret matches between backend settings and OnlyOffice server config
- OnlyOffice server is accessible from the backend host (not just from the browser)
Related Topics
- OnlyOffice API - API endpoints
- Architecture - System architecture
Last updated on