> For the complete documentation index, see [llms.txt](https://wp-launchpad.gitbook.io/launchpad/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://wp-launchpad.gitbook.io/launchpad/tutorials/index/index-1.md).

# Plugin life circle

Inside WordPress a plugin always follows the following life circle:

{% @mermaid/diagram content="stateDiagram-v2
\[\*] --> Activated: Activate
Activated --> Deactivated: Deactivate
Deactivated --> Activated: Activate
Deactivated --> Uninstalled: Uninstall" %}

It is possible to take advantage of it, to execute some code at one of these steps.

## Activate

The activate logic is a logic that will be executed when the plugin is installed or re-activated.

Launchpad offers [an easy way to add logic](/launchpad/tutorials/index/index-1/activate.md) to execute on this step.

## Deactivate

The deactivate logic activated when the plugin is disabled.

Launchpad offers [an easy way to add logic](/launchpad/tutorials/index/index-1/deactivate.md) to execute on this step.

## Uninstall

The uninstall logic is activated when the plugin is deleted.

Launchpad offers [a module to add logic](/launchpad/tutorials/index/index-1/uninstall.md) to execute on this step.
