diff --git a/src/km3io/tools.py b/src/km3io/tools.py
index c684219728d953ec256d4eed865d9a1582148991..c2d8a829b387c0672631cd6f7c04c1e4749a152d 100644
--- a/src/km3io/tools.py
+++ b/src/km3io/tools.py
@@ -536,3 +536,14 @@ def is_3dmuon(trigger_mask):
       A value or an array of the trigger_mask, either of an event, or a hit.
     """
     return is_bit_set(trigger_mask, ktrg.JTRIGGER3DMUON)
+
+
+def is_nanobeacon(trigger_mask):
+    """Returns True if the trigger mask contains the nano-beacon flag.
+
+    Parameters
+    ----------
+    trigger_mask : int or array(int)
+      A value or an array of the trigger_mask, either of an event, or a hit.
+    """
+    return is_bit_set(trigger_mask, ktrg.JTRIGGERNB)