This article was last updated on : October 28th, 2016 at 10:55 am

ERROR 2003 (HY000): Can’t connect to MySQL server on ‘localhost’ (10061)

I have installed MySQL version 5.6 on windows 7. My Installation was successful and without any error. I received “ERROR 2003 (HY000): Can’t connect to MySQL server on ‘localhost’ (10061)” while I was trying to start MySQL server from command prompt. I am attaching the screenshot of the error I received.

Image of command prompt while starting MySQL Server
Starting MySQL From Command Prompt

When I could not connect to MySQL server installed on my windows. I tried to connect MySQL Server directly by using “MySQL5.6 Command Line Client”. Same error was occurring and MySQL Command line was disappearing.

I was little worried of this error – ERROR 2003 (HY000). I did not get any of issues while installing MySQL5.6 on windows so MySQL server should work properly.
I did search on internet (MySQL forum, DB related forums) and I resolved Can’t connect to MySQL server on ‘localhost’ (10061) error. Now I was able to run MySQL server from command prompt.

Reason for ERROR 2003 (HY000): Can’t connect to MySQL server on ‘localhost’ (10061) – MySQL services has not been started.

Please see the steps below to fix this problem.

1. Please Log in as Admin to your System.
2. Open your Task Manager panel.
3. Go to Services tab.
4. See there for MySQL presence. It will look like this image given below.In my case it is displayed like MySQL56.

Image Showing Services tab in Task Manager
Showing MySQL Services Status using Task Manager

In the above image you can see that MySQL56 service is showing as Stopped. Please see the blue dark line in the image.

5. Please select MySQL56 and do right click. You will get Start option. Select Start command to start MySQL Services. Please see the below image for your reference.

Image displaying how to start mysql server from task manager services tab
Image Showing how to start MySQL server from task manager

6. Please recheck that MySQL service has been started successfully.
7. In case MySQL services do not start using this way, It means you are not logged in with Admin account. In this case you will receive this error.

Access is not possible
Getting Error if not logged in as Admin

Please follow next given steps to start MySQL service from Administrative Panel.
8. Please Go to  Control Panel > All Control Panel Items > Administrative Tools.
9. Please go to Services. Below image is showing the process.

Showing Administrative tools
Image showing Services in Administrative Tools

10. Please select MySQL56 under Name column.
11. Please click on start link from left panel to start MySQL Service. Please see the image below for your refrence.

Image showing how to install mysql server manually from services
Starting MySQL server from Administrative panel

12. Once MySQL service started. Please go to MySQL bin directory using command prompt and retype the command >mysql -u root -p mysql
13. Please enter your MySQL password.
14. We can see image given below after MySQL server started successfully.

Command prompt showing mysql server started successfully
MySQL Server Started Successfully from Command prompt

Thanks for reading this post. Please let me know if your problem has been resolved.

Share this post:

Recent Posts

19 Comments

  1. Avatar for Tarun Singh
    rutwik says:

    thankyou very much for your visual feedback

  2. Avatar for Tarun Singh
    Ben says:

    Thank you Tarun. An excellent explanation of how to solve the problem.

  3. Avatar for Tarun Singh
    Sunnu PS says:

    Was working on this problem for 1 hour (at least !) when I fall on your explanation. Now it works like magic. Thanks a lot !

  4. Avatar for Tarun Singh
    Dinesh vishe says:

    Hi ,
    I am unable to start sql service.There is no service for myssql.
    tell me solution.

    • Avatar for Tarun Singh
      Tarun Singh says:

      Thanks Dinesh for writing your problem. It seems MySql has not been installed on your system completely. Once it is installed on your system it would be shown in services. Please go to Control Panel and Uninstall it. Unistall all the dependencies and all the folders from you System. After doing all these again install it. It should work fine. I would recommend you to run .msi file.

  5. Avatar for Tarun Singh
    Aisha says:

    Thank You Sir
    It really solved the issue 🙂

  6. Avatar for Tarun Singh
    Joydeep says:

    Thank you sir……….:) your explanation have solved my problem..

  7. Avatar for Tarun Singh
    Dinesh S says:

    In the services, when i click in start link for mysql the following error is diplayed “windows could not start the windows search service on local computer error 2”

    • Avatar for Tarun Singh
      Tarun Singh says:

      Hi Dinesh, Many developer face this kind of problem. Please check 1. Are you trying to install right version compatible with your operating system. 2. Please check your firewall settings.
      Please let me know your windows configuration. I will send you link for installation.

  8. Avatar for Tarun Singh
    Dinesh S says:

    In the services, when i click in start link for mysql the following error is diplayed “windows could not start the MySql service on local computer. Error 2”

  9. Avatar for Tarun Singh
    NIkunj Gupta says:

    Thanks tarun. It really solved my problem. Great solution

  10. Avatar for Tarun Singh
    Rebecca Fausto says:

    I’ve done everything youve mentioned. Unfortunately, I’m still getting the same error message.

  11. Avatar for Tarun Singh
    Nick Parsons says:

    Hello. My problem is the same as Dinesh. No service file even though Mysql is installed on my system. Need help.

    Thanks

    Nick

    • Avatar for Tarun Singh
      Tarun Singh says:

      Hello Nick! In case MySql was earlier installed on your system, please delete your temp files and data files related to MySql. Again re-install MySql. Go to services and check if MySql services are running. Please let me know for further doubts.

  12. Avatar for Tarun Singh
    Vicky says:

    Now also shows unexpected error on Window 10 please give a solution,.

Leave a Comment

| | 0 | term_meta | 4 3172 | set | put in cache | | 0 | term_meta | 4 3173 | get | from in-call cache | | 0 | term_meta | 5 3174 | set | put in cache | | 0 | term_meta | 5 3175 | get | from in-call cache | | 0 | term_meta | 6 3176 | set | put in cache | | 0 | term_meta | 6 3177 | get | from in-call cache | | 0 | term_meta | 8 3178 | set | put in cache | | 0 | term_meta | 8 3179 | get | from in-call cache | | 0 | term_meta | 9 3180 | set | put in cache | | 0 | term_meta | 9 3181 | get | from in-call cache | | 0 | term_meta | 11 3182 | set | put in cache | | 0 | term_meta | 11 3183 | get | from in-call cache | | 0 | term_meta | 14 3184 | set | put in cache | | 0 | term_meta | 14 3185 | get | from in-call cache | | 0 | term_meta | 15 3186 | set | put in cache | | 0 | term_meta | 15 3187 | get | from in-call cache | | 0 | term_meta | 16 3188 | set | put in cache | | 0 | term_meta | 16 3189 | get | from in-call cache | 200 | 0 | options | notoptions 3190 | get | from in-call cache | 239363 | 0 | options | alloptions 3191 | get | from in-call cache | 200 | 0 | options | notoptions 3192 | get | from in-call cache | 239363 | 0 | options | alloptions 3193 | get | from in-call cache | 200 | 0 | options | notoptions 3194 | get | from in-call cache | 239363 | 0 | options | alloptions 3195 | get | from in-call cache | 200 | 0 | options | notoptions 3196 | get | from in-call cache | 239363 | 0 | options | alloptions 3197 | get | from in-call cache | 200 | 0 | options | notoptions 3198 | get | from in-call cache | 239363 | 0 | options | alloptions 3199 | get | from in-call cache | 200 | 0 | options | notoptions 3200 | get | from in-call cache | 239363 | 0 | options | alloptions 3201 | get | from in-call cache | 200 | 0 | options | notoptions 3202 | get | from in-call cache | 239363 | 0 | options | alloptions 3203 | get | from in-call cache | 200 | 0 | options | notoptions 3204 | get | from in-call cache | 239363 | 0 | options | alloptions 3205 | get | from in-call cache | 200 | 0 | options | notoptions 3206 | get | from in-call cache | 239363 | 0 | options | alloptions 3207 | get | from in-call cache | 200 | 0 | options | notoptions 3208 | get | from in-call cache | 239363 | 0 | options | alloptions 3209 | get | from in-call cache | 200 | 0 | options | notoptions 3210 | get | from in-call cache | 239363 | 0 | options | alloptions 3211 | get | from in-call cache | | 0 | terms | get_terms:8259b0f16977a5346dcdfebd72648b2c:0.59836400 1487622795 3212 | set | put in cache | 2986 | 0 | terms | get_terms:8259b0f16977a5346dcdfebd72648b2c:0.59836400 1487622795 3213 | get | from in-call cache | 295 | 0 | terms | 2 3214 | get | from in-call cache | 200 | 0 | options | notoptions 3215 | get | from in-call cache | 239363 | 0 | options | alloptions 3216 | get | from in-call cache | 326 | 0 | terms | 7 3217 | get | from in-call cache | 200 | 0 | options | notoptions 3218 | get | from in-call cache | 239363 | 0 | options | alloptions 3219 | get | from in-call cache | 327 | 0 | terms | 10 3220 | get | from in-call cache | 200 | 0 | options | notoptions 3221 | get | from in-call cache | 239363 | 0 | options | alloptions 3222 | get | from in-call cache | 306 | 0 | terms | 12 3223 | get | from in-call cache | 200 | 0 | options | notoptions 3224 | get | from in-call cache | 239363 | 0 | options | alloptions 3225 | get | from in-call cache | 305 | 0 | terms | 13 3226 | get | from in-call cache | 200 | 0 | options | notoptions 3227 | get | from in-call cache | 239363 | 0 | options | alloptions 3228 | get | from in-call cache | 329 | 0 | terms | 17 3229 | get | from in-call cache | 200 | 0 | options | notoptions 3230 | get | from in-call cache | 239363 | 0 | options | alloptions 3231 | get | from in-call cache | 408 | 0 | terms | 55 3232 | get | from in-call cache | 200 | 0 | options | notoptions 3233 | get | from in-call cache | 239363 | 0 | options | alloptions 3234 | get | from in-call cache | 328 | 0 | terms | 56 3235 | get | from in-call cache | 200 | 0 | options | notoptions 3236 | get | from in-call cache | 239363 | 0 | options | alloptions 3237 | get | from in-call cache | 314 | 0 | terms | 57 3238 | get | from in-call cache | 200 | 0 | options | notoptions 3239 | get | from in-call cache | 239363 | 0 | options | alloptions 3240 | get | from in-call cache | 200 | 0 | options | notoptions 3241 | get | from in-call cache | 239363 | 0 | options | alloptions 3242 | get | from in-call cache | 200 | 0 | options | notoptions 3243 | get | from in-call cache | 239363 | 0 | options | alloptions 3244 | get | from in-call cache | 412 | 0 | users | 14 3245 | get | from in-call cache | 3593 | 0 | user_meta | 14 3246 | get | from in-call cache | 200 | 0 | options | notoptions 3247 | get | from in-call cache | 239363 | 0 | options | alloptions 3248 | get | from in-call cache | 200 | 0 | options | notoptions 3249 | get | from in-call cache | 239363 | 0 | options | alloptions 3250 | get | from in-call cache | 200 | 0 | options | notoptions 3251 | get | from in-call cache | 239363 | 0 | options | alloptions 3252 | get | from in-call cache | 200 | 0 | options | notoptions 3253 | get | from in-call cache | 239363 | 0 | options | alloptions 3254 | get | from in-call cache | 200 | 0 | options | notoptions 3255 | get | from in-call cache | 239363 | 0 | options | alloptions 3256 | get | from in-call cache | 200 | 0 | options | notoptions 3257 | get | from in-call cache | 239363 | 0 | options | alloptions 3258 | get | from in-call cache | 200 | 0 | options | notoptions 3259 | get | from in-call cache | 239363 | 0 | options | alloptions 3260 | get | from in-call cache | 200 | 0 | options | notoptions 3261 | get | from in-call cache | 239363 | 0 | options | alloptions 3262 | get | from in-call cache | 200 | 0 | options | notoptions 3263 | get | from in-call cache | 239363 | 0 | options | alloptions 3264 | get | from in-call cache | 200 | 0 | options | notoptions 3265 | get | from in-call cache | 239363 | 0 | options | alloptions 3266 | get | from in-call cache | 200 | 0 | options | notoptions 3267 | get | from in-call cache | 239363 | 0 | options | alloptions 3268 | get | from in-call cache | 200 | 0 | options | notoptions 3269 | get | from in-call cache | 239363 | 0 | options | alloptions 3270 | get | from in-call cache | 200 | 0 | options | notoptions 3271 | get | from in-call cache | 239363 | 0 | options | alloptions 3272 | get | from in-call cache | 200 | 0 | options | notoptions 3273 | get | from in-call cache | 239363 | 0 | options | alloptions 3274 | get | from in-call cache | 200 | 0 | options | notoptions 3275 | get | from in-call cache | 239363 | 0 | options | alloptions 3276 | get | from in-call cache | 200 | 0 | options | notoptions 3277 | get | from in-call cache | 239363 | 0 | options | alloptions 3278 | get | from in-call cache | 200 | 0 | options | notoptions 3279 | get | from in-call cache | 239363 | 0 | options | alloptions Page Caching using disk: enhanced Page cache debug info: Engine: disk: enhanced Cache key: sitenol.com/error-2003-hy000-cant-connect-to-mysql-server-on-localhost-10061/_index.html Creation Time: 1487622838.000s Header info: Content-Type: text/html; charset=UTF-8 X-Powered-By: W3 Total Cache/0.9.5.2 X-Pingback: http://sitenol.com/xmlrpc.php Link: ; rel="https://api.w.org/" Link: ; rel=shortlink Served from: sitenol.com @ 2017-02-20 20:33:58 by W3 Total Cache -->