WordPress GuidePlugins → Check Active

How to check if a WordPress plugin is active

Need to know whether a plugin is currently active on your WordPress site? Whether you’re debugging an issue, writing custom code, or just curious about what’s running, checking plugin status is easier than you might think.

Let’s walk through five easy ways to do it—both from the dashboard and with code—plus one powerful bonus method many tutorials skip.

Get fast, reliable hosting for WordPress

Power your site with the industry’s fastest, most optimized WordPress hosting

Why you might need to check plugin status

There are plenty of good reasons to check whether a specific plugin is active on your site or in your code:

Depending on your technical comfort level, you can use the admin interface, a few lines of PHP, or even WP-CLI to find the answer.

Method 1: Check plugin status in the WordPress dashboard

This is the easiest method and doesn’t require any code.

This method is perfect for visual confirmation or quick checks.

Method 2: Use is_plugin_active() in your code

If you’re writing PHP for a theme or plugin, the is_plugin_active() function is the most reliable method.

Here’s how to use it:

Make sure you include the plugin.php file first—this function isn’t available by default on the frontend. Also note that the plugin path must match its folder and main file name exactly.

You can find the correct path by visiting the Plugins screen and hovering over the “Edit” or “Deactivate” link for that plugin.

Method 3: Use function_exists() or class_exists()

If you don’t want to hardcode the plugin filename, you can check for a function or class that the plugin defines.

For example:

This is a great fallback method when the plugin’s filename might vary or when you only care about whether a key feature is available.

Method 4: Check plugin status from the database

If you’re building something advanced or need to scan active plugins globally (like in a multisite setup), you can fetch the list directly from the options table:

On multisite installations, you’ll also want to check sitewide_active_plugins using get_site_option():

$network_plugins = get_site_option( ‘active_sitewide_plugins’ );

This method is more complex but very useful when building tools or dashboards.

Method 5: Use WP-CLI to check plugin status

If you have SSH access and WP-CLI installed, you can check plugin status right from the terminal.

To list all plugins and their status:

wp plugin list

To check if a specific plugin is installed and active:

wp plugin is-installed woocommerce && echo “Installed”

wp plugin is-active woocommerce && echo “Active”

This is a must-have method for anyone managing multiple environments or automating deployments.

Bonus: Avoid fatal errors with safe plugin checks

Some plugins only load functions or classes under certain conditions. To avoid fatal errors:

For example:

This ensures the plugin has had time to fully load before you attempt to use its features.

Additional resources

What is a WordPress plugin? →

A complete beginner’s guide to WordPress plugins and how to manage them

Floating Google reviews plugin for WordPress: Top 3 options and how to choose →

Showcase social proof and build trust by displaying floating Google reviews on your website.

How to check if a plugin is safe →

Simple steps to evaluating a plugin before you install and activate it