WordPress: "Plugin could not be activated because it triggered a fatal error"
You clicked Activate and WordPress refused, with a red box and a line of PHP underneath. The good news: WordPress caught the crash before it switched the plugin on, so your site is still running exactly as before. The line under the message tells you why the plugin crashed. Here is how to read it, and the fix for each case.
What the owner sees
harborbakery.example/wp-admin/plugins.php
What the checks found
Find out which case it is (five minutes)
Read the line under the message. It usually starts with Fatal error: or Parse error: and names a file and a line. If it is blank, add define('WP_DEBUG', true); define('WP_DEBUG_LOG', true); to wp-config.php, click Activate again, and read wp-content/debug.log.
Look for "Cannot redeclare" or "already declared". Two copies of the same code are loading: an old and a new copy of the plugin, a free and a Pro version, or a theme that bundles the same library.
Look for "syntax error, unexpected" or "requires PHP". The plugin needs a newer PHP than your server runs. Tools, Site Health, Info, Server shows your PHP version; the plugin page on wordpress.org shows what it needs.
Look for "Call to undefined function" or "Class not found". Either a PHP extension is missing on the server (mbstring, intl, zip, gd, curl) or the plugin is an add-on that needs its parent plugin active first.
Look for "Allowed memory size exhausted". The plugin needs more PHP memory than the server gives.
The fixes, by case
Cannot redeclare / already declared: deactivate and delete the other copy first (the free version before installing Pro, or an old folder such as plugin-name-1 left by a failed update), then activate. If the clash names your theme, ask the theme or plugin author which one should drop the bundled library.
Syntax error or "requires PHP 8.x": raise the PHP version in your hosting panel (most hosts have a one-click PHP selector). Test on a staging copy first if your other plugins are old. Or install the last plugin version that supports your PHP.
Missing PHP extension: enable it in the hosting panel's PHP extensions list, or send your host a one-line ticket naming the extension from the error.
Undefined function from a parent plugin: add-ons for WooCommerce, Elementor, ACF and the like need the parent installed and active first. Activate the parent, then the add-on.
Memory exhausted: add define('WP_MEMORY_LIMIT', '256M'); to wp-config.php; if the host caps it lower, ask them to raise memory_limit.
Incomplete upload: a "failed to open stream" or "No such file" error points at a file that is not there. Delete the plugin and install it again from Plugins, Add New, or upload a fresh zip.
A nulled or "free premium" copy: delete it. These are a common source of crashes and of hidden malware. Get the plugin from its author.
What you see, what it means, what it needs
What you see
What it means
Usual fix
Cannot redeclare ... / already declared
Two copies of the same code
Delete the old or free copy, then activate
syntax error, unexpected ... / requires PHP
Server PHP is too old for the plugin
Raise PHP in the hosting panel
Call to undefined function mb_...
A PHP extension is missing
Enable the extension or ask the host
Class "WooCommerce" not found
Add-on activated before its parent
Activate the parent plugin first
Allowed memory size exhausted
PHP memory limit too low
WP_MEMORY_LIMIT 256M or host raises it
failed to open stream: No such file
The upload was incomplete
Delete and reinstall the plugin
What not to do
Do not keep clicking Activate. Nothing changes until the cause does.
Do not edit the plugin's files to remove the failing line. The next update undoes it and the plugin may break in a worse place.
Do not downgrade PHP to suit one plugin. Old PHP is a security risk for the whole site.
Do not leave WP_DEBUG on once you have read the error; set it back to false.