Reset SA Password in Sql Server

SA user (abbreviation for "System Administrator") is the administrative login for MS SQL Server. What do you do if you forgot SQL Server SA password ? Reinstall MS SQL Server or just drop everything and walk out of here? For whatever reason, if you forgot your SQL Server SA password and the windows account told you don’t have the permissions to change it, this article will demonstrate several options for resetting your SQL SA password.

These steps work for SQL Server 2005, 2008, 2012 and later.

Steps

Option 1: Change SQL SA password from a command prompt

  1. Go to the command prompt of the server and type in command prompt osql –L
  2. Copy full name of SQL Server and type: OSQL -S <insert_servername_here> -E
  3. Execute the following query: sp_password NULL, ‘<insert_new_password_here>’, ’sa’
  4. GO

Option 2: Reset SA password using SSMS

  1. Open SSMS management console. This is usually under Start -> All Programs -> Microsoft SQL Server 2005 -> SQL Server Management Studio Express.
  2. Connect to your instance of SQL Server via Windows Authentication.
  3. Once open, navigate to “Logins” object under the “Security”. Once expanded, right-click on the ‘SA’ user, and choose Properties.
  4. Now, enter desired password in front of “Password” and “Confirm Password” field and click OK.

Option 3: Reset SA password with SQL Password Recovery Tool

  1. Run the SQL Password Recovery program and then click “Open” to load the master .mdf file.
  2. Select SA user name to reset the forgotten SA password, or select any other user name which you forgot the password. Click “Change Password” to reset password.
  3. Enter the preferential password and click “OK”.

Option 4: When You Have SA Disabled

  1. It's an extra tricky scenario; sometimes SA is disabled.
  2. Start SQL server as single user using -m flag via command line.
  3. Run as Administrator
  4. On the Server Roles page, select sysadmin and reset password.

Tips

  • The easiest and most efficient way to reset SA password is to take use of SQL Password Recovery Tool. You can use some SQL Password Recovery tool to reset SQL SA password successful on SQL. Such as SQL Password Geeker, SQL Password Rescuer.