Resolving High Disk and CPU Usage Caused by Google Site Kit
Content
Users of the Google Site Kit plugin sometimes encounter unexpected server resource issues, such as excessive disk space consumption or high CPU usage. These problems can lead to warnings from your hosting provider, server slowdowns, or even your website going offline. This guide explains the common causes and provides steps to resolve these resource-related issues.
Why This Happens
Based on community reports and analysis, these resource spikes are typically not caused by the plugin's normal operation. The most common triggers are:
- Incomplete Plugin Updates or Migrations: During an update or site migration, files may not be overwritten correctly. This can leave behind outdated or redundant files in the plugin's
dist/js/directory, causing it to balloon in size to hundreds of megabytes. - False-Positive Malware Flags: Some server-side antivirus or security scanners may incorrectly flag the plugin's compiled JavaScript files (e.g.,
googlesitekit-vendor-....js) as potential malware, leading to quarantined files and plugin dysfunction. - Background Processes: In rare cases, a stuck or looping process within the plugin can cause abnormally high and sustained CPU usage.
How to Troubleshoot and Fix the Issue
Solution 1: Perform a Clean Reinstall (For Disk Space Issues)
If your hosting dashboard shows that the Google Site Kit plugin folder (often in wp-content/plugins/google-site-kit/) is consuming a very large amount of space (e.g., over 400MB), a clean reinstall is the most effective solution.
- Go to your WordPress dashboard and deactivate the Google Site Kit plugin.
- Delete the plugin. This will remove all of its files from your server.
- Install a fresh copy of Google Site Kit from the WordPress Plugin Directory or by uploading the ZIP file.
- Reactivate and reconnect the plugin to your Google services. Your settings are stored in your database and should reappear once reconnected.
This process ensures all old, potentially corrupted files are purged and replaced with a clean installation, which should return the plugin's folder to its normal size (around 15-20MB).
Solution 2: Check for False Malware Positives (For Security Warnings)
If your host has quarantined Site Kit files, first perform the clean reinstall described above. Then, contact your hosting provider's support and inform them that the files were from an official, trusted WordPress plugin. You can request that they whitelist the plugin's dist/ directory to prevent future false positives.
Solution 3: Isolate High CPU Usage
If you are experiencing high CPU loads that normalize when Site Kit is deactivated, follow these steps:
- Ensure you have manually placed any essential Google service code (like Analytics or Tag Manager) on your site before deactivating Site Kit for testing.
- Perform the clean reinstall (Solution 1), as corrupted files can also cause performance loops.
- After reinstalling, monitor your server's CPU usage. If the problem is resolved, the corruption was likely the cause.
When to Seek Further Help
If these steps do not resolve the issue, the problem may be specific to your server environment. In such cases, you can seek help from the wider community by clearly describing the problem, the steps you have already taken, and your site's environment (PHP version, WordPress version, other active plugins).
Related Support Threads Support
-
Google site kit consumes a lot of spacehttps://wordpress.org/support/topic/google-site-kit-consumes-a-lot-of-space/
-
High Cpu usage by Site kit pluginhttps://wordpress.org/support/topic/high-cpu-usage-by-site-kit-plugin/
-
Refus par le serveurhttps://wordpress.org/support/topic/refus-par-le-serveur/