Disable/enable logging in Magento from database

Disable/enable logging in Magento from database

July 8, 2026 · Illustrated author avatarBy Stefan Bogdanescu
Disable/enable logging in Magento from database

Disabling/Enabling Logging in Magento via Database

As an experienced developer working on e-commerce applications, I understand that sometimes administrative access may be restricted, making it challenging to enable or disable logging through the standard interface. In such cases, you can directly modify the database settings.

Accessing the Configuration Table

The Magento configuration is stored in the core_config_data table located in your database schema.

SELECT * FROM core_config_data WHERE path = 'developer/log/active';

This query will return the current status of logging. The value field contains either “1” for enabled or “0” to disable logging.

Enabling Logging via Database

To enable logging, update the value field to 1:

UPDATE core_config_data SET value = '1' WHERE path = 'developer/log/active';

This operation will immediately turn on all log settings configured in Magento. You can verify this by checking if any log files are being created in your var/log directory.

Disabling Logging via Database

If you need to disable logging for some reason, simply update the value field back to 0:

UPDATE core_config_data SET value = '0' WHERE path = 'developer/log/active';

This will stop all Magento logs from being generated. It’s a quick and efficient way to manage your log settings when admin access is limited.

Caveats and Best Practices

While this direct database approach works effectively, I recommend using it judiciously:

  1. Always take a backup: Before making any changes directly in the database, ensure you have a recent backup of all data.
  2. Log Settings Configuration: Remember that enabling logging saves all Magento activity to files, which can quickly consume storage space if left unmanaged.

If you find yourself frequently modifying these settings or dealing with large log files, consider implementing a more sophisticated log rotation strategy using cron jobs or a dedicated logging service.

Conclusion

Enabling or disabling logging directly in the database provides a quick and efficient solution when admin access is restricted. However, it’s crucial to understand the implications of logging on your system resources.

For a more comprehensive understanding of Magento configuration management, I recommend reading our guide on Configuring Magento Settings Efficiently at Laravel Company.

This blog post provides best practices and advanced techniques for managing Magento configurations in both admin and database contexts.

Database API Admin Configuration

Our network