Pipeline file structure

When you create a new pipeline from the nf-core template, the tool generates a complete directory structure containing numerous files and folders. Some files serve as boilerplate that requires minimal modification, while others are essential to understand during pipeline development.

This page describes the files and directories that nf-core pipelines create generates when running with all template options enabled, and explains the purpose and function of each component.

Files

You will find the following files in each nf-core pipeline. They are automatically generated when running nf-core pipelines create.

FilenameDescription
main.nfThe main Nextflow file that is executed when the pipeline runs. Typically, parameters are initialized and validated in this script before a workflow from the workflows/ directory is called for execution.
nextflow.configThe main Nextflow configuration file. It contains the default pipeline parameters, Nextflow configuration options, and information such as pipeline and minimum Nextflow version. The nextflow.config also defines different configuration profiles that can be used to run the pipeline. See the Configuration docs for more information.
README.mdBasic information about the pipeline and usage.
nextflow_schema.jsonThe JSON schema file used for pipeline parameter specification. Automatically created using the nf-core pipelines schema build command. It is used for printing command-line help, validating input parameters, building website documentation, and generating pipeline launch interfaces (web and CLI).
CHANGELOG.mdInformation about the changes made to the pipeline for each release.
LICENSEThe license file for the pipeline (MIT license).
CODE_OF_CONDUCT.mdThe nf-core code of conduct.
CITATIONS.mdCitations for tools and references used by the pipeline.
.gitattributesGit settings that configure .config files to render with Nextflow syntax highlighting on GitHub.
.gitignoreFiles that should be ignored by Git.
.editorconfigEditorConfig file that helps ensure consistent coding style.
.prettierrc.ymlPrettier configuration file to ensure consistent Markdown formatting.
modules.jsonMetadata file that tracks information (e.g., version) about all modules installed from nf-core/modules.
.nf-core.ymlConfiguration file that indicates the repository type (pipeline or modules) and stores pipeline metadata for nf-core/tools, such as linting exceptions and skipped template features.
ro-crate-metadata.jsonRO-Crate metadata file that provides a standardized description of the pipeline. For more information, see RO-Crate.

Directories

Directory nameDescription
.devcontainerConfiguration files for GitHub Codespaces development environments.
.github/GitHub-specific files, including issue templates, pull request templates, and GitHub Actions workflows.
assets/Additional pipeline resources such as example input files, reference data, and documentation assets.
bin/Scripts that are directly accessible within pipeline processes. Files in this directory can be called from within Nextflow processes without specifying the full path.
conf/Configuration files for the pipeline. Includes base.config (defines CPU and memory requirements for low, medium, and high resource processes), igenomes.config (specifies locations for reference genomes), test.config and test_full.config (test configurations), and modules.config (module-specific settings).
docs/Markdown files for pipeline documentation.
modules/Pipeline-specific modules and shared nf-core modules.
workflows/Main pipeline workflows that are executed from the main.nf file.
subworkflows/Smaller subworkflows that typically consist of a few modules chained together.