How does Nextcloud logging work and how can I access them?
Nextcloud logging records and documents all relevant events and processes within your cloud environment, helping you monitor the system’s status and detect potential errors early. The storage location of the information, as well as how you access the Nextcloud logs, depends on the log variant you choose.
What is meant by Nextcloud logging?
Nextcloud logging refers to the collection and documentation of system-relevant information within a Nextcloud instance. This feature is primarily used to monitor the system’s status and identify potential sources of errors at an early stage. Logging also helps track unusual activities and security-related events, such as unauthorised access attempts. The collected information is stored in logs that administrators can analyse to ensure the smooth operation of the cloud or resolve any issues.
Another important tool for the long-term protection of your Nextcloud instance is the versioning feature, which is enabled by default and allows you to restore older file versions. You can read more about this feature in the separate article on Nextcloud Versioning.
What Nextcloud log levels are there?
Nextcloud distinguishes between five logging levels that indicate the extent of information being logged. These Nextcloud log levels are as follows:
0 – DEBUG: At this level, all activities are recorded, making it the most detailed logging level within a Nextcloud instance.
1 – INFO: This level logs file activities, user logins, as well as warnings, errors and critical errors.
2 – WARN: Besides errors and critical errors, Nextcloud logging at level 2 also records successful operations that have led to warnings about potential issues.
3 – ERROR: Only critical errors and failed operations, which do not negatively affect other services aornd operations, are recorded.
4 – FATAL: Logging only occurs in this case if the server is stopped.
The parameters for the logging level are defined in the config/config.php file. In the Nextcloud config.php, the default log level is set to 2 (WARN). For troubleshooting, it is advisable to enable DEBUG. However, after error analysis, the log level should be reverted to a less detailed level. Since DEBUG logs a large volume of information, the server’s performance may be affected.
If you use Managed Nextcloud by IONOS, you can avoid the administrative effort of installing, maintaining and updating your cloud server. This allows you to fully focus on using your cloud and Nextcloud apps. Benefit from secure server infrastructure and high data protection standards!
What Nextcloud logs are there and where can they be found?
Nextcloud offers users various types of logs to document activities and processes. These include errorlog, file, syslog, and systemd - four different logging options, which we will explain in more detail below.
Depending on the preferred logging method, the log_type parameter in the config/config.php file must be set to ‘errorlog’, ‘file’, ‘syslog’, or ‘systemd’.
errorlog
With this method, all log information is sent to error_log(), which means it is stored in the web server’s error log file. The location of this file depends on the server’s configuration. For example, if Apache is used, you would typically find the file located at/var/log/apache2/error.log`. However, you can generally change the location manually at any time.
file
All Nextcloud logs are stored in a separate file, which is named nextcloud.log by default and located in the /var/www/nextcloud/data/ directory path. You can specify the file name using the logfile parameter, and optionally set the desired date format with the logdateformat parameter in config/config.php.
syslog
All log information is sent to the central daemon programme of the cloud software. This refers to a continuously running background process that handles periodic service requests.
systemd
With this type of Nextcloud logging, the logs are stored in the systemd journal, which manages the services running on the system. The PHP extension php-systemd must be installed for this method.
How to open Nextcloud logs
If you use file-based Nextcloud logging, you can easily view all log data through the admin settings (under ‘Logging’). This feature is provided by the Log Reader app, which also allows you to download log files. For other logging options, logs can be opened with a text editor and/or via the command line.

- Keep your data safe with industry-leading security
- Save time on updates and maintenance
- Easily add apps and online office tools

