Rediger

Del via


Download and install the bcp utility

Applies to: SQL Server Azure SQL Database Azure SQL Managed Instance Azure Synapse Analytics Analytics Platform System (PDW) SQL database in Microsoft Fabric

The bulk copy program utility (bcp) bulk copies data between an instance of SQL Server and a data file in a user-specified format.

For detailed information about using bcp with Azure Synapse Analytics, see Load data with bcp.

Identify installed version

To determine the installed version of bcp, run the following command:

bcp -v

If multiple versions of bcp are installed on Windows, the PATH environment variable determines which one runs. To list every copy of bcp.exe on the search path, use the following command:

where bcp.exe

For information about how to set the command path in the PATH environment variable, see Environment variables.

bcp versioning

The bcp utility is versioned independently of the SQL Server release it ships with:

bcp major version Distribution
18 Ships with SQL Server 2025 (17.x). Adds -Y (TLS encryption mode) and -u (trust server certificate) switches.
15 Distributed as Microsoft Command Line Utilities 15 for SQL Server, and bundled with SQL Server 2019 (15.x) and SQL Server 2022 (16.x) tools.

Download the latest version

The following instructions are for bcp running on Windows. For instructions on installing bcp on Linux and macOS, as well as system requirements, see Install the sqlcmd and bcp SQL Server command-line tools on Linux.

Package Platform
Microsoft Command Line Utilities 15 for SQL Server x64x86

The Microsoft Command Line Utilities package contains both bcp and sqlcmd (ODBC). It also installs (or requires) the Microsoft ODBC Driver for SQL Server.

Note

The standalone bcp download might not have the same release and build number as the bcp that ships with the latest SQL Server cumulative update (CU). This behavior is expected. The standalone download still contains all fixes included in the latest CU.

System requirements

The following system requirements are for bcp running on Windows.

Get help

Contribute to SQL documentation

Did you know that you can edit SQL content yourself? If you do so, not only do you help improve our documentation, but you also get credited as a contributor to the page.

For more information, see Edit Microsoft Learn documentation.