> For the complete documentation index, see [llms.txt](https://docs.snyk.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.snyk.io/supported-languages/supported-languages-list/dart-and-flutter.md).

# Dart and Flutter

Snyk support for Dart and Flutter with Snyk Code and Snyk Open Source, including Early Access code analysis on Enterprise plans

{% hint style="info" %}
**Snyk is rolling out a new navigation.** The steps on this page describe the classic interface. If your view looks different, visit [Navigate the Snyk Web UI](https://docs.snyk.io/navigate-the-snyk-web-ui#where-things-moved) to map these options to the new interface.
{% endhint %}

## Dart and Flutter

{% hint style="info" %}
Snyk supports Dart and Flutter for Snyk Code and Snyk Open Source.
{% endhint %}

### Dart and Flutter for Snyk Code

{% hint style="info" %}
Code analysis support for Dart is in Early Access and is available only with Enterprise plans. To enable the feature, visit [Snyk Preview](https://docs.snyk.io/platform-administration/snyk-hierarchy/snyk-preview).
{% endhint %}

For an overview of the supported security rules, visit [Dart and Flutter rules](https://docs.snyk.io/scan-fix-and-prevent/scan-with-snyk/snyk-code/snyk-code-security-rules/dart-and-flutter-rules).

#### Supported frameworks and libraries

For Dart and Flutter with Snyk Code, Snyk supports the following frameworks and libraries:

{% columns %}
{% column %}

* crypto
* encrypt
* uuid
* basic\_utils
* pointycastle
* cryptography
* sqflite
* sqlite3
* drift
* realm
* http
* dio
* cupertino\_http
* web\_socket\_channel
* web
  {% endcolumn %}

{% column %}

* cronet\_http
* flutter\_inappwebview
* webview\_flutter
* twilio\_flutter
* dart\_eval
* google\_sign\_in
* flutter\_facebook\_auth
* sign\_in\_with\_apple
* flutter\_appauth
* openid\_client
* firebase\_auth
* amplify\_flutter
* flutter\_stripe
* nfc\_manager
* mobile\_scanner
* flutter
  {% endcolumn %}
  {% endcolumns %}

#### Supported file formats

Snyk supports the following file formats: `.dart`

#### Available features

* Reports
* Interfile analysis

### Dart and Flutter for Snyk Open Source

#### Available features

* Test your app's SBOM and packages using `pkg:pub` PURLs through the [SBOM test](https://docs.snyk.io/developer-tools/snyk-cli/snyk-cli/commands/sbom-test) CLI command
* Test and monitor the native platform dependencies of your Flutter apps using the [`snyk test`](https://docs.snyk.io/developer-tools/snyk-cli/snyk-cli/commands/test) and [`snyk monitor`](https://docs.snyk.io/developer-tools/snyk-cli/snyk-cli/commands/monitor) commands

#### Testing the pub dependency tree of a Dart application

Activate the pub [`sbom`](https://pub.dev/packages/sbom) package and create a minimal `sbom.yaml` file in the root folder of the repository:

```
dart pub global activate sbom
cat << EOF > sbom.yaml
type: spdx
spdx:
  SPDXFormat: 'tagvalue'
EOF
```

Use the Dart `sbom` command to create an SBOM file, and test it using the [`sbom test`](https://docs.snyk.io/developer-tools/snyk-cli/snyk-cli/commands/sbom-test) command:

```
dart pub global run sbom
snyk sbom test --experimental --file sbom-pub.json
```

#### Testing platform dependencies (iOS, macOS, Android) in Flutter apps

Flutter applications rely on native platform dependencies to handle lower-level tasks, such as analytics, hardware access, or integrating existing functionality. You can add these dependencies through pub packages to extend functionality, or integrate them directly into build systems such as Gradle or CocoaPods.

Snyk Open Source can scan these packages. However, you must complete an app build to make the packages available in the repository and accessible to CLI tools.

Start by building the application for all relevant platforms. This ensures that `pub` fetches all required packages, and the Flutter build system establishes the necessary links for the native build systems.

```
flutter build apk --debug
flutter build ios --debug --no-codesign
flutter build macos --debug
```

Next, run the `snyk monitor` command to scan for native dependencies:

```
snyk monitor --all-projects --exclude=example,.symlinks
```

The `--exclude` parameter removes duplicates and ignores example applications, which are part of the plugin source code but not included in regular application builds.

You can now view all native dependencies in the Snyk Web UI, including those introduced by third-party plugins.

<figure><img src="https://476084957-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FL7HyJj9FsK1W4pNt8Gzl%2Fuploads%2Fgit-blob-9c9a0662e7b32f22a90a905187245ee1bb0b0dfa%2Fsnyk-project-page-showing-dependencies-flutter-apps.png?alt=media" alt="Snyk Project page showing dependencies in Flutter apps"><figcaption><p>Snyk Project page showing dependencies in Flutter apps</p></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.snyk.io/supported-languages/supported-languages-list/dart-and-flutter.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
