Introduction to Snyk Code custom rules

You can run custom rules as part of any scan run by Snyk Code, and the feature is available when you are using Snyk Code in any of the following:

Prerequisite Before using the feature, you must enable Snyk Code custom rules in Snyk Preview.

Using custom rules in the Snyk Web UI

You can create and test queries in a local environment, completely separate from your current Snyk scans. Perform one of the following actions in Snyk Web UI:

Using custom rules in the Snyk CLI

You can test your Code Projects using the Snyk CLI with regular commands and options as long as you have the .snyk file to hold any custom rules that you have created using Snyk Web UI.

For more information, see Using Snyk Code via the CLI.

Using custom rules in the IDE

IDE integrations with Snyk support custom rules as long as you have the .snyk file to hold any custom rules that you have created using Snyk Web UI.

For more information, see Using Snyk Code via the IDE.

Additional resource

To learn from an end-to-end example, see the Snyk Learn course Snyk Code Custom Rules.

Last updated

More information

Snyk privacy policy

© 2023 Snyk Limited | All product and company names and logos are trademarks of their respective owners.