2020-10-29 11:09:12 -04:00
---
2021-02-05 04:09:10 -05:00
stage: Verify
group: Pipeline Authoring
2020-11-26 01:09:20 -05:00
info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments
2020-10-29 11:09:12 -04:00
---
2020-11-26 01:09:20 -05:00
<!-- markdownlint - disable MD044 -->
2021-01-29 16:09:34 -05:00
<!-- vale gitlab.Spelling = NO -->
2020-11-26 01:09:20 -05:00
# Validate .gitlab-ci.yml syntax with the CI Lint tool
<!-- markdownlint - enable MD044 -->
2021-01-29 16:09:34 -05:00
<!-- vale gitlab.Spelling = YES -->
2020-08-12 11:10:02 -04:00
If you want to test the validity of your GitLab CI/CD configuration before committing
the changes, you can use the CI Lint tool. This tool checks for syntax and logical
errors by default, and can simulate pipeline creation to try to find more complicated
issues as well.
To access the CI Lint tool, navigate to **CI/CD > Pipelines** or **CI/CD > Jobs**
in your project and click **CI lint** .
## Validate basic logic and syntax
By default, the CI lint checks the syntax of your CI YAML configuration and also runs
2021-06-28 17:10:13 -04:00
some basic logical validations. Configuration added with the [`includes` keyword ](yaml/index.md#include ),
2020-11-13 10:09:24 -05:00
is also validated.
2020-08-12 11:10:02 -04:00
To use the CI lint, paste a complete CI configuration (`.gitlab-ci.yml` for example)
into the text box and click **Validate** :
![CI Lint ](img/ci_lint.png )
## Pipeline simulation
> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/229794) in GitLab 13.3.
Not all pipeline configuration issues can be found by the [basic CI lint validation ](#validate-basic-logic-and-syntax ).
You can simulate the creation of a pipeline for deeper validation that can discover
more complicated issues.
To validate the configuration by running a pipeline simulation:
1. Paste the GitLab CI configuration to verify into the text box.
1. Click the **Simulate pipeline creation for the default branch** checkbox.
1. Click **Validate** .
![Dry run ](img/ci_lint_dry_run.png )
### Pipeline simulation limitations
Simulations run as `git push` events against the default branch. You must have
[permissions ](../user/permissions.md#project-members-permissions ) to create pipelines
on this branch to validate with a simulation.