[Microsoft Docs, Troubleshoot common connection issues]: Add the client IP to the logical server's firewall rules in the Azure portal. Also confirm port 1433 is open for outbound connections on every firewall between the client and the internet (Error 5 variant). Never pin the server FQDN to a specific IP in a hosts file: Azure SQL gateways rotate, and a stale override produces login failures (18456/40532/40615) isolated to one network.

Context: Connecting to Azure SQL Database fails with Error 40615: Cannot open server. The server firewall has rejected the client IP, so the connection never reaches the login stage.

## Matched source
Source: Source: https://github.com/microsoftdocs/sql-docs/blob/HEAD/azure-sql/database/troubleshoot-common-errors-issues.md
Original query: "Azure SQL Database: Error 40615 server firewall rejected the client IP"
Key terms: 40615, azure, client, database, error, firewall, rejected, server
