Newer Version Available
Error: API Version Mismatch
If you update Salesforce CLI and try to push source from your local DX project to a
scratch org, you see an API version error.
1sfdx force:source:push
2ERROR running force:source:push: The configured apiVersion 51.0 is not supported for this org. The max apiVersion is 50.0What happened?
Answer: Your locally configured apiVersion is greater than your org’s supported max apiVersion. To troubleshoot, first run this command to determine if your local apiVersion is overridden:
1sfdx config:listTo resolve the error for a specific project, set the apiVersion locally:
sfdx config:set apiVersion=50.0
To resolve the error for all Salesforce DX projects, set the apiVersion globally:
sfdx config:set apiVersion=50.0 -g
To override the API version for a single CLI command execution, use the --apiversion parameter:
1sfdx force:source:push --apiversion=50.0