diff --git a/multiple_select.module b/multiple_select.module
index 18d9089..119f017 100644
--- a/multiple_select.module
+++ b/multiple_select.module
@@ -4,7 +4,8 @@
  * @file
  * Multiple select module file.
  */
-
+use Drupal\Core\Hook\Attribute\LegacyHook;
+use Drupal\multiple_select\Hook\MultipleSelectHooks;
 use Drupal\Core\Routing\RouteMatchInterface;
 use Drupal\Core\Url;
 
@@ -137,31 +138,7 @@ function multiple_select_get_bulk_configs() {
 /**
  * Implements hook_help().
  */
+#[LegacyHook]
 function multiple_select_help($route_name, RouteMatchInterface $route_match) {
-  switch ($route_name) {
-    case 'help.page.multiple_select':
-      $output = '';
-      $output .= '<h2>' . t('About') . '</h2>';
-      $output .= '<p>' . t('The Multiple Select module provides a Form API checkbox element with a
-				"Select / Unselect All" functionality for checkboxes fields. This module has
-				a configuration page in which this functionality can be applied to one (or more)
-				<a href=":node_help" title="Node module help">node</a> or <a href=":media_help" title="Node module help">media</a> types.</a>',
-        [
-          ':field_help' => Url::fromRoute('help.page', ['name' => 'field'])->toString(),
-          ':node_help' => Url::fromRoute('help.page', ['name' => 'node'])->toString(),
-          ':media_help' => Url::fromRoute('help.page', ['name' => 'media'])->toString(),
-        ])
-        . '</p>';
-      $output .= '<h2>' . t('Uses') . '</h2>';
-      $output .= '<dl>';
-      $output .= '<dt>' . t('Enabling bulk select') . '</dt>';
-      $output .= '<dd>' . t('	In order to add a bulk select helper, the website must have at least one
-				field which its field settings allows more than one values and with widget settings
-				(on Form display)set to "Check boxes".
-				You can define which field (or fields) of a content entity (node or media) should
-				display this helper.')
-        . '</dd>';
-      $output .= '</dl>';
-      return $output;
-  }
+  return \Drupal::service(MultipleSelectHooks::class)->help($route_name, $route_match);
 }
diff --git a/multiple_select.services.yml b/multiple_select.services.yml
new file mode 100644
index 0000000..3408fe6
--- /dev/null
+++ b/multiple_select.services.yml
@@ -0,0 +1,5 @@
+
+services:
+  Drupal\multiple_select\Hook\MultipleSelectHooks:
+    class: Drupal\multiple_select\Hook\MultipleSelectHooks
+    autowire: true
diff --git a/src/Hook/MultipleSelectHooks.php b/src/Hook/MultipleSelectHooks.php
new file mode 100644
index 0000000..0bcc776
--- /dev/null
+++ b/src/Hook/MultipleSelectHooks.php
@@ -0,0 +1,51 @@
+<?php
+
+namespace Drupal\multiple_select\Hook;
+
+use Drupal\Core\Routing\RouteMatchInterface;
+use Drupal\Core\Url;
+use Drupal\Core\Hook\Attribute\Hook;
+use Drupal\Core\StringTranslation\StringTranslationTrait;
+/**
+ * Hook implementations for multiple_select.
+ */
+class MultipleSelectHooks
+{
+    use StringTranslationTrait;
+    /**
+     * Implements hook_help().
+     */
+    #[Hook('help')]
+    public function help($route_name, \Drupal\Core\Routing\RouteMatchInterface $route_match)
+    {
+        switch ($route_name) {
+            case 'help.page.multiple_select':
+                $output = '';
+                $output .= '<h2>' . $this->t('About') . '</h2>';
+                $output .= '<p>' . $this->t('The Multiple Select module provides a Form API checkbox element with a
+				"Select / Unselect All" functionality for checkboxes fields. This module has
+				a configuration page in which this functionality can be applied to one (or more)
+				<a href=":node_help" title="Node module help">node</a> or <a href=":media_help" title="Node module help">media</a> types.</a>', [
+                    ':field_help' => \Drupal\Core\Url::fromRoute('help.page', [
+                        'name' => 'field',
+                    ])->toString(),
+                    ':node_help' => \Drupal\Core\Url::fromRoute('help.page', [
+                        'name' => 'node',
+                    ])->toString(),
+                    ':media_help' => \Drupal\Core\Url::fromRoute('help.page', [
+                        'name' => 'media',
+                    ])->toString(),
+                ]) . '</p>';
+                $output .= '<h2>' . $this->t('Uses') . '</h2>';
+                $output .= '<dl>';
+                $output .= '<dt>' . $this->t('Enabling bulk select') . '</dt>';
+                $output .= '<dd>' . $this->t('	In order to add a bulk select helper, the website must have at least one
+				field which its field settings allows more than one values and with widget settings
+				(on Form display)set to "Check boxes".
+				You can define which field (or fields) of a content entity (node or media) should
+				display this helper.') . '</dd>';
+                $output .= '</dl>';
+                return $output;
+        }
+    }
+}
