# Extend a Nightfall Detector

You can customize a Nightfall detector to meet your organization's requirements. Once you customize a Nightfall detector, it is considered to be a custom detector. The Nigytfall detector that you used and customized, continues to exist as is.&#x20;

Nightfall provides you with two customization options. Context rules and Exclusion rules. You must use at least one of these two rules to customize a Nightfall detector. The procedure to use Context rules and Exclusion rules is the same as in the case of Regular Expression Detector. You can learn how to configure Context rules and Exclusion rules from the[#understanding-context-rules-and-exclusion-rules](https://help.nightfall.ai/detection_platform/regexp_detector#understanding-context-rules-and-exclusion-rules "mention") document.&#x20;

To extend a Nightfall Detector:

1. Navigate to the Detectors section from the left pane.
2. Click **+ Custom Detector** and select **Extend a Nightfall detector**.
3. Select the Nightfall detector that you wish to customize.&#x20;
4. Enter a name for the customized detector in the **Name** field.&#x20;
5. (Optional) Enter a description for the detector in the **Description** field.&#x20;
6. Click **Next**.

<figure><img src="https://2214688951-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-Mg3wgFIu8T7XAT1u-f_%2Fuploads%2FDAFjbBEYOh7CLUEXZdZj%2Fimage.png?alt=media&#x26;token=0c8299d1-3ef4-4c0e-abb2-3ee4675eccce" alt=""><figcaption></figcaption></figure>

7. Click **+ Add Context Rule** to configure the context rule.
8. Click **Save** to save the rule.
9. Click **Next**.&#x20;
10. Click **+ Add Token Rule** to configure token rules.&#x20;
11. Click **Save** to save the rule.
12. Click **Next**.&#x20;

{% hint style="info" %}
It is mandatory to either define the Context rule or the Token rule.&#x20;
{% endhint %}

13. Review the configurations and click **Add**.

<figure><img src="https://2214688951-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-Mg3wgFIu8T7XAT1u-f_%2Fuploads%2FAp3rVcux2xg85b9ijiMJ%2Fimage.png?alt=media&#x26;token=2a3d6197-f36a-4d34-925f-4bab099276c2" alt=""><figcaption></figcaption></figure>
