How to Enable WordPress Automatic Updates — Secure Your Site in Minutes
WordPress automatic updates are an easy, effective way to keep your site secure and free up time. This guide walks you through how they work, when to enable them, and practical setup tips—like using system cron and correct permissions—to make updates reliable and safe.
Automatic updates are a crucial part of maintaining a secure, stable WordPress site. For site owners, developers, and enterprises running multiple installations, enabling and managing automatic updates can reduce the window of exposure to known vulnerabilities and free up operational time. This article explains the technical workings, practical scenarios, pros and cons, configuration options, and deployment recommendations so you can enable WordPress automatic updates confidently and safely.
How WordPress automatic updates work — underlying principles
WordPress provides several layers of automatic update functionality out of the box and via hooks and filters for granular control. Understanding these mechanics helps you choose the right strategy for your environment.
Core update types
- Minor core updates (security and maintenance): Enabled by default. These are applied automatically through the dashboard or WP-Cron and are considered safe to apply without manual testing.
- Major core updates (feature releases): Disabled by default. These can introduce breaking changes; you can enable them selectively when you have appropriate testing in place.
- Plugin updates: Disabled by default for automatic updates. Can be enabled per-plugin or globally via filters or the site UI (since WP 5.5).
- Theme updates: Disabled by default. Similar to plugins, can be toggled per-theme or via code.
Execution model: WP-Cron vs system cron
By default, automatic updates are scheduled and executed through WP-Cron, which is triggered by site traffic. On low-traffic sites this can delay updates. For reliable and timely updates, many sysadmins disable WP-Cron and configure a system-level cron job to invoke WordPress updates, for example:
wget -q -O - https://example.com/wp-cron.php?doing_wp_cron >/dev/null 2>&1
Using a system cron (or a management tool) ensures updates run at predictable intervals and reduces the overhead of on-request cron execution.
Permissions and file system requirements
Automatic updates require WordPress to write to plugin, theme, and core directories. On Linux VPS hosts this means ensuring correct ownership and permissions:
- Files typically owned by the web server user (e.g.,
www-data,apache, ornginx), or using a deployment user with appropriate group access. - Directories commonly set to
755and files to644. Sensitive files likewp-config.phpcan be stricter. - If WordPress cannot write to the filesystem, updates will fail. Using SSH/FTP credentials configured in
wp-config.phpor defining direct file system methods can help (define('FS_METHOD', 'direct');when safe).
Practical configuration methods
There are multiple ways to enable or customize automatic updates. Choose the method that fits your maintenance workflow and security posture.
Using constants in wp-config.php
Add the following lines to enable major core updates and control behavior:
define('WP_AUTO_UPDATE_CORE', true);— enables all core updates, including major releases.define('AUTOMATIC_UPDATER_DISABLED', false);— ensures the automatic updater is enabled (default behavior).
Note: Constants are applied early in the bootstrap process and are less flexible than filters, but they’re simple for global site-level policies.
Using filters in a mu-plugin or functions.php
For fine-grained control, add filters in a must-use plugin (wp-content/mu-plugins) or a site-specific plugin:
add_filter('auto_update_plugin', '__return_true');— enable automatic plugin updates (global)add_filter('auto_update_theme', '__return_true');— enable automatic theme updatesadd_filter('allow_dev_auto_core_updates', '__return_true');— allow updates on development branches
Per-plugin or per-theme control can be achieved by attaching logic to the filter and checking the plugin or theme slug.
WP-CLI and automation
WP-CLI gives you scripted control over updates. On a VPS or managed host, set a cron job to run WP-CLI commands such as:
wp core update --minor
wp plugin update --all --quiet
This approach enables deterministic scheduling outside of WordPress internals, logging of results, and integration with orchestration tools or CI/CD pipelines.
Application scenarios and recommended strategies
Different environments need different update policies. Below are recommended approaches for common scenarios.
Single small business site
- Enable automatic minor core updates (default).
- Enable plugin and theme automatic updates for non-critical plugins or those known to be stable.
- Maintain daily backups and enable update email notifications.
Agency or multisite hosting multiple client sites
- Prefer scheduled WP-CLI updates with logging so you can audit which updates deployed and when.
- Run automatic updates on a staging clone first, then promote to production after smoke tests.
- Use per-plugin whitelisting: only enable auto-updates for low-risk plugins (security, minor maintenance). For complex plugins, require manual QA.
Enterprise or high-availability deployments
- Disable automatic major core updates in production; integrate updates into your CI/CD pipeline with automated tests.
- Use canary or blue/green deployments and database migration strategies to avoid downtime.
- Automate rollback procedures (database snapshots, code versioning) and keep frequent backups off-site.
Pros and cons — advantage comparison
Evaluate the trade-offs before committing to a global automatic update policy.
Advantages
- Reduced risk exposure: Security patches are applied quickly without manual intervention.
- Operational efficiency: Less manual maintenance, especially valuable for multiple sites.
- Consistency: Sites stay on supported versions, reducing technical debt.
Disadvantages and risks
- Compatibility breakage: Major updates or plugin changes can cause conflicts and downtime.
- Insufficient testing: Automated updates may deploy unverified changes to production.
- Permission and environment issues: Misconfigured file permissions or restrictive SELinux/AppArmor can cause partial failures and inconsistent states.
Operational best practices and safeguards
To get the benefits while minimizing risk, follow these technical best practices.
Backups and snapshots
- Take automated database and file backups before updates. Use daily or immediate pre-update snapshots if your VPS supports it.
- Store backups in a remote location (S3, object storage) with lifecycle policies.
Staging and automated testing
- Use a staging environment to run plugin and theme updates first. Automate unit or integration tests and smoke checks.
- For high traffic sites, use a replica environment to validate front-end rendering and critical flows.
Monitoring, logging, and notifications
- Enable update notification emails in WordPress or use an external monitoring system (Datadog, New Relic) to catch regressions.
- Log all WP-CLI update runs with timestamps and exit statuses so you can perform post-mortems.
Rollback planning
- Keep a documented rollback procedure. For code rollbacks, use Git tags and for DB rollbacks, maintain snapshots compatible with your restore process.
- Consider plugin-specific rollback tools or automatic reinstatement of previous versions if an update fails critical checks.
Choosing hosting and configuration for safe automatic updates
Your hosting environment matters greatly. A VPS gives you the control to implement safe, repeatable update strategies.
When selecting a VPS, consider:
- Root/SSH access: Necessary for setting system cron jobs, WP-CLI, and secure file permissions.
- Snapshot/backup capabilities: Instant snapshots make pre-update backups fast and reliable.
- Performance: Adequate CPU and I/O for running tests and background update tasks without affecting production traffic.
- Security features: Firewall, private networking, and optional managed services reduce risk exposure.
If you prefer a provider that balances performance and control, review their snapshot and backup options and ensure they support SSH and cron scheduling. For example, VPS.DO provides flexible USA VPS instances with SSH access and snapshot capabilities suitable for the update workflows described here (see the link at the end).
Implementation checklist — quick technical summary
- Decide which updates to auto-apply: minor core, major core, plugins, themes.
- Configure updates via constants (wp-config.php) or filters (mu-plugin) as appropriate.
- Prefer system cron + WP-CLI or managed cron to eliminate WP-Cron timing issues.
- Ensure correct file ownership and permissions for update operations.
- Automate backups/snapshots immediately prior to updates.
- Use staging environments and automated tests for major changes.
- Enable monitoring and maintain rollback documentation.
Example: pragmatic setup for a small-to-medium site
- Enable default minor core auto-updates (leave major core disabled).
- Enable automatic updates for security-focused plugins only; use WP-CLI nightly for non-security plugin updates with a pre-update backup snapshot.
- Run a system cron at 03:00 UTC to call WP-CLI commands and capture logs to /var/log/wp-updates.log.
Conclusion
Automatic updates are a powerful tool to reduce risk and operational burden, but they require careful configuration and safeguards to avoid unexpected downtime. Use WordPress filters or wp-config constants to control which types of updates you allow, prefer system-level scheduling (WP-CLI or cron) for reliability, and always combine updates with automated backups, staging validation, and monitoring.
For operators who want full control over the update environment—SSH access, snapshotting, and predictable performance—deploying on a capable VPS is often the best choice. If you’re evaluating hosting options that support robust update workflows, you can start with a provider like VPS.DO. Their USA VPS offerings provide SSH access and snapshot features that make implementing the cron/WP-CLI approach straightforward; see details at https://vps.do/usa/.