There is no WordPress hook to filter the current status on the plugins admin, but if you must, you can use $_REQUEST['plugin_status']
to change the default status.
See example below where I use the load-plugins.php
hook to ensure we’re changing the status (or modifying the superglobal $_REQUEST
) only on the plugins.php
page:
function wpse_373622() {
if ( ! isset( $_REQUEST['plugin_status'] ) ) {
$_REQUEST['plugin_status'] = 'active';
}
}
add_action( 'load-plugins.php', 'wpse_373622' );