# Fixing plugins that disappear from the WordPress admin

> Find out why plugins vanish from the WordPress Plugins page, usually a hacked site, and how to restore them.

Source: https://helpcenter.ruachost.com/wordpress/guides/stopping-wordpress-plugins-disappearing-from-the-admin-page/

Sometimes WordPress plugins may suddenly disappear from the **Plugins** section in the admin dashboard. This usually indicates a deeper issue with your site. On **ruachost.com**, you can identify the cause and restore your plugins by following these steps.

## Why Do Plugins Disappear?

- ### Site Compromise (Most Common Cause)

  - If your site has been hacked, malicious code may be injected into plugin files.
  - WordPress checks plugin metadata when you install, update, or delete a plugin. If metadata is missing or corrupted, WordPress removes the plugin from the list.
- ### Code Injection Exploits

  - Hackers often inject malicious code into plugin files.
  - This code may spread to other PHP files across your site.
  - Infected files can send spam, advertise hacker groups, or even launch DDoS attacks.
- ### Metadata Corruption

  - Each plugin requires a header comment with details like name, version, and author.
  - If this metadata is altered or missing, WordPress hides the plugin from the admin page.

## How to Fix the Issue

### 1. Confirm the Problem

- Check if plugins are missing from the **Plugins** menu.
- Review your site for unusual behavior (spam emails, redirects, slow performance).

### 2. Clean Up After a Hack

- Follow standard cleanup procedures:

  - Back up your site.
  - Scan files with a security plugin (e.g., Wordfence, Sucuri).
  - Remove malicious code from infected files.
  - Replace compromised plugins/themes with fresh copies.

### 3. Restore Plugin Metadata

- Ensure each plugin’s main file contains the required header comment:

  ```
  /*
  Plugin Name: Example Plugin
  Plugin URI: https://example.com
  Description: Short description of the plugin
  Version: 1.0
  Author: Author Name
  Author URI: https://author-site.com
  */
  ```
- If metadata is missing, WordPress will not display the plugin.

### 4. Harden Your Site

- Update WordPress, plugins, and themes regularly.
- Use strong passwords and two‑factor authentication.
- Install a firewall plugin to block suspicious activity.
- Regularly back up your site to restore quickly if compromised.

> **Note:**
- WordPress does not periodically check for missing metadata, plugins only disappear when modified.
- If plugins vanish repeatedly, it’s a strong sign of ongoing compromise.
- Always investigate the root cause rather than just reinstalling plugins.
