dbatools is a free PowerShell module with over 300 SQL Server administration, best practice and migration commands included.

Please note that documentation and command names may be out of date while we work furiously towards 1.0


This command copies configuration values (sp_configure) from one SQL Server to another. By default, all configuration values are copied.

The -Configs parameter is autopopulated for command-line completion and can be used to copy only specific configs.


To copy all sp_configure settings from sqlserver2014a to sqlcluster using integrated (Windows) authentication


To update the values for two configs, the IsSqlClrEnabled and DefaultBackupCompression, from sqlserver2014a to sqlcluster, using SQL credentials for sqlserver2014a and Windows credentials for sqlcluster


To see what would happen if the command were executed



From PowerShell, execute Get-Help Copy-DbaSpConfigure -Detailed for more information on this function.

Source Code

Want to see the source code? View Copy-DbaSpConfigure.ps1 on GitHub

Related commands