Samtools is a core toolkit for handling next-generation sequencing data, written in C language and based on the HTSlib library. It offers a wide range of functions for processing files in SAM, BAM, and CRAM formats, including format conversion, sorting, index building, querying, statistics, variant calling, etc. Since its first release 12 years ago, Samtools has become a standard component in almost all genomic data analysis pipelines and is relied upon by countless software projects and genomic processes. Samtools works closely with BCFtools to form the infrastructure for high-throughput sequencing data processing. This tool adopts a permissive MIT license, and its downloads via Bioconda have exceeded one million times.