Immutable solution version
Azure SQL error 18456: login failed means bad credentials or disabled login
Complete solution
Azure SQL error 18456: login failed means bad credentials or disabled login. To check a disabled login, run SELECT name, is_disabled FROM sys.sql_logins in master; enable it with ALTER LOGIN [name] ENABLE. Use when hitting this exact issue with Azure SQL error 18456. Not for unrelated errors or different features.
When it applies
Not specified by the original author.
Instructions
TL;DR
To check a disabled login, run SELECT name, isdisabled FROM sys.sqllogins in master; enable it with ALTER LOGIN [name] ENABLE. 'Login failed for user' (Error 18456) means the username or password is wrong, or the login is disabled: ask the service administrator for valid credentials.
The error
login failed means bad credentials or disabled loginFix
To check a disabled login, run SELECT name, isdisabled FROM sys.sqllogins in master; enable it with ALTER LOGIN [name] ENABLE. Expected: You see the expected output instead of the problem.
Re-run the original operation and confirm the error is gone. Expected: no error, normal output.
When to use
- You hit this exact error with Azure SQL error 18456.
- The symptom matches: login failed means bad credentials or disabled login.
When NOT to use
- A different error message from Azure SQL error 18456; the cause here is specific to this error.
- Unrelated Azure SQL error 18456 issues (different feature, different failure).
- You need general documentation for the tool; check the official docs instead.
Compatibility
Reported against Azure SQL error 18456. Source: https://github.com/microsoftdocs/sql-docs/blob/HEAD/azure-sql/database/troubleshoot-common-errors-issues.md.
Variant phrasings
login failed means bad credentials or disabled login
Why it happens
18456 is never a network error. Check the login itself.
Edge cases
- If your error message differs even slightly, this is probably a different issue; search the exact text.
- If the fix does not help, capture the full error output and check the source link for updates.
Source
https://github.com/microsoftdocs/sql-docs/blob/HEAD/azure-sql/database/troubleshoot-common-errors-issues.md
Evidence
Source: 18456 is never a network error. Check the login itself.
Verified resolution: [Microsoft SQL docs]: 'Login failed for user' (Error 18456) means the username or password is wrong, or the login is disabled: ask the service administrator for valid credentials. To check a disabled login, run SELECT name, isdisabled FROM sys.sqllogins in master; enable it with ALTER LOGIN [name] ENABLE. If the login does not exist, create it with CREATE LOGIN in master, then create the user in the target database and grant permissions. Save the tracing ID from the error message for support.
Source URL: https://github.com/microsoftdocs/sql-docs/blob/HEAD/azure-sql/database/troubleshoot-common-errors-issues.md
By @issueatlas · Version 3 · Exact version
Maintainer review
Checking maintainer review for this exact version…
A maintainer review records the library version checked. It does not assert that it is the latest upstream release. Reported outcomes are separate evidence.
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_KB99Y2JLBakpsgwSD5JNkw" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">Azure SQL error 18456: login failed means bad credentials or disabled login <span>— Vectle</span></a>