If you’re like me and get the urge to mess around with your PC then this might interest you or if you’re seriously looking to setup an IIS Server along with MySQL & phpMyAdmin then again, this is for you. This is a quick how-to for setting up MySQL & phpMyAdmin on Windows if you’re planning to install WordPress or any such application dependent on these technologies. There are other options like Xampp but I’d like to talk about how one can set these components individually. Setting up an IIS Server is quite easy & so is MySQL & phpMyAdmin, so here’s how:
-
Setting up IIS (Windows 7):
To do this follow these steps:
-
Start –> Control Panel
-
Programs –> Uninstall a program
-
Turn Windows features on or off (left sidebar)
-
Check ‘Internet Information Services’ & ‘Internet Information Services Hostable Web Core’.
-
OK. Sreenshot:

Once the installation is done, you’ll have to start the server. To do this:
-
Start
-
Search for IIS –> Select IIS Manager
-
Select your PC from the left sidebar & hit ‘Start’ on the right sidebar. Screenshot:

-
Install MySQL:
Now that IIS is installed, we’ll set up MySQL, to do that:
-
Run the setup
-
Select the ‘Typical’ setup & keep hitting Next & Install.
Screenshots:
Once MySQL wizard completes it will ask you whether you want to register the server & if you want to configure the server. To save time & hassle, we’ll uncheck the registration option & will configure the server, screenshots:
We’ll choose the Standard configuration & enter the required details. Configurations screenshots:
Security settings, I’d suggest keep something that you’ll remember & nothing to complicated. Set the MySQL service to auto run saving you time. Screenshots:
Last screen, press ‘Execute’ & once done, ‘Finish’. You’re done with MySQL installation & setup. :)

-
Installing phpMyAdmin:
We’ll be installing phpMyAdmin as it’s a GUI to managing the tables:
-
Extract it to:C:\inetpub\wwwroot\phpmyadmin
-
Now navigate to the same directory & rename the file config.sample.inc.php to config.inc.php
-
Open the file in Notepad & find$cfg[‘blowfish_secret’] = ‘ ’;
-
Within the ‘ ’ insert any word, eg: manan. The line should look like:$cfg[‘blowfish_secret’] = ‘manan’;
-
Save the file. Note that the file name should be config.inc.php
-
In your browser, go to:localhost/phpmyadmin
-
And that’s it, login with the credentials you provided during the MySQL. If all’s done right & the php God’s are smiling you should see your login page, something like this:
~Enjoy!
Wait for the follow up post that would explain my reasoning for going through all of this :)
After doing lots of practices to Install, PHP & MySQL on Windows XP. I am now on WampServer.
Actually the problem is that PHP & MySQL have no patchup in XP.
Isn’t?
I haven’t tired it on XP but there shouldn’t be any problem IMO.
Any idea why the MySQL service fails to start? I keep getting “Could not start the service MySQL” from the Instance Configuration Wizard. I have removed the service and the “instance”, uninstalled and reinstalled many times, and still cannot get the service to start.
Follow the steps below:
1.stop the service and instance.
2.uninstall mysql.
3.remove the mysql folder from progamme files.
4.Now here is the issue. if using xp. go to windows explorer, tolls>folder options>views>check show hidden files and folders.
5. go to c: documents and settings > all users > application data> there is a folder called mysql. delete this folder even from recycle bin.
6. install it again. it must work now.
if using windows 7 or vista.
in step 4 go to c: programme files and go to programme data and delte mysql folder.
install it again.
should be fine now. worked for me.
Thanks.
Hi Sean, I’ currently not on the machine I’ve set this up, but since you said its a service not starting issue try the following:
Start -> Run -> services.msc & search for a MySQL service here, see if it is disabled or something. I’lll check this up on my other machine as well, if I can duplicate the issue & find a solution. :)
Hey, I’ve removed the service multiple times using ‘sc’ from the command line. There are no MySQL, MySQL51, etc. services present. As it turns out, it had something to do with the my system really not liking InnoDB. Once I told it to configure a “transactionless” server, everything worked fine.
Actually, I’m working on a much larger problem. I need some sort of a server setup for testing purposes on my Windows 7 desktop. I’ve tried the builtin IIS, and made large strides, but in the end encountered so many headaches, that I gave up. I think I’m gonna try one of the old devside.net server suites. I need something to experiment with Joomla!, which uses mysql and php. Permissions on IIS7.5 turned out to be hellishly complicated… maybe Apache will work better for me.
Anyways, thanks for your response! :)
Hey Sean, interesting wouldn’t have found that honestly. If you’re trying to do something like that, I’d suggest you use a Windows Server OS. They’re comparatively more hassle free from what I’ve seen, though not done much on this end.
Yeah, perhaps, but from what I’ve seen, Windows Server 2008 looks quite similar to IIS 7.5 embeded in Windows 7 Ultimate. It’s funny, I place more confidence in an Apache configuration running on top of Windows… and ironically, it seems to be working quite a bit better. It’s a lot easier setting all the permissions in conf files, than trying to use a combination of that stupid IIS_IUSRS account and the very confusing GUI associated with IIS.
Thanx a lot manan,
it helped a lot!
This was a HUGE help! One thing though: the Windows Installer version of PHP does not install the mcrypt extension and you can see from the screen shots that phpMyAdmin complains about that. I don’t know if it’s crucial or not to have it, but I hate errors so I found out how to fix it. Simply go to Control Panel, Programs, right-click on PHP 5.2.11 and select change. Then add the mcrypt extension. Then add these lines to the php.ini file:
[PHP_MCRYPT]
extension=php_mcrypt.dll
thanks for the heads up! Appreciate it :)
The best method is to go for WAMP, a no brainer for configuration and hence a developer can focus on web development instead of figuring out ways to get things up and running.
True there are alternatives. I had to use this for WPI and it helps a lot. ;)
Manan,
I followed all the steps you have posted. I could get as far as the login page of phpmyadmin .I am unable to login after that . I get the error “#2002 – The server is not responding (or the local MySQL server’s socket is not correctly configured)” . How to get past this ? Thanks in advance.
I have the same error. I had install XAMPP in winXP and the apache service works fine but when i try to run phpmyadmin it get me that error.
Very helpful, thank you!
you’re welcome :)
Which is my curruent root password?
I have a connection error n.1405.
I try with all my password but nothing. What can i do?
thank’s
You only use the current root password if you already have MySQL database installed, If you don’t don’t type anything in there.
Hello everyone,
I have followed the instructions thoroughly, yet I am receiving “Error 404.0” cannot find. I renamed the file as stated in the phpmyadmin folder. The code was edited properly and I even used the example word ‘manan’. Please someone help me I am losing my mind over this.
Thanks in advance.
Hey Manan, thank you so much for your post! I wouldn’t know where to get started without following your instructions. Thank you ^^
I did what was posted but when I go to localhost/phpmyadmin on my internet browser, all i see is a directory and not a login page. Am I doing something wrong? please help!
buddys …… this is what i find so far…. all you need is to go to this file… root:/xampp/mysql/bin/my.conf ..
root = your root directory where xampp is intalled…
and search for words like socket=’Mysql’
That ‘Mysql’ is an actuall problem. put this there (root:/xampp/mysql/mysql.sock)
like soket=’root:/xampp/mysql/mysql.sock’
restart .. i hope it should work :D…
i guess i will work on all OS too, but mine case is windows 7
Thank so much for this tutorial. It was clear, concise and extremely helpful to me.
Rhonda Fairman
After installing phpmyadmin from the link I found in this page, could login into phpmyadmin with my old password without problem before I set the blowfish password and changed the file name as explained in the tutorial above… but once I have set up a new blowfish password and changed the name of the file as explained, I can’t login into mysql server, phpmyadmin and I cannot change the mysql password from the command line… I have tried a lot of manners I have found but anything helps.
ok this post it been a weile ??
I’m refering to Beingmanan last writing “Wait for the follow up post that would explain my reasoning for going through all of this ”
Ok where is the follow up post ??Where is the link??
https://beingmanan.com/wp/2009/07/install-wordpress-on-pc-with-web-platform-installer/
Thanks for the indepth tutorial but, upon entering the domain name “localhost/phpmyadmin”, a 404 error saying”The resource you are looking for has been removed, had its name changed, or is temporarily unavailable” loads.
@2521b8f6b6683ee780e5dbf9114fb040:disqus try using the IP address using this format: http://11.222.333.444/myphpadmin/index.php
Good tutorial, pulled me out of a world of pain with toySQL. Thanks,
its fantastic guide…but i have one query..
Could you please post same type of tutorial for how to setup remote mysql db server in windows …….i mean to say web server is different and database server is different………………
if you post this artical here please let me know at [email protected]..i will be highly grateful to you……………………
thanx it helped
I am install all my SQL and phpmyadmin follow the steps but i have this “#1045 Cannot log in to the MySQL server” type of error
Thank you,,,,,,,,,,,,
dear sir, I am trying the open the phpmyadmin getting the bellow error.
http://licalhost working fine
http://localhost/phpmyadmin/
it shows parent
directory credits
i try to open the http://localhost/phpmyadmin/index.php
we are getting the bellow error please help me sir please,
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="” lang=”” dir=””>phpMyAdmin – <meta http-equiv="Content-Type" content="text/html; charset=” />// <![CDATA[ // definitions used in common.js var common_query = '’; var opendb_url = ”; var safari_browser = ; var querywindow_height = ; var querywindow_width = ; var collation_connection = ”; var lang = ”; var server = ”; var table = ”; var db = ”; var token = ”; var text_dir = ”; var pma_absolute_uri = ”; var pma_text_default_tab = ”; var pma_text_left_default_tab = ”; // for content and navigation frames var frame_content = 0; var frame_navigation = 0; function getFrames() { frame_content = window.frames[1]; frame_navigation = window.frames[0]; frame_content = window.frames[0]; frame_navigation = window.frames[1]; } var onloadCnt = 0; var onLoadHandler = window.onload; window.onload = function() { if (onloadCnt == 0) { if (typeof(onLoadHandler) == “function”) { onLoadHandler(); } if (typeof(getFrames) != ‘undefined’ && typeof(getFrames) == ‘function’) { getFrames(); } onloadCnt++; } };// ]]><frameset cols="” rows=”*” id=”mainFrameset”> <frame frameborder="0" id="frame_navigation" src="navigation.php” name=”frame_navigation” /> <frame frameborder="0" id="frame_content" src="” name=”frame_content” /> <frame frameborder="0" id="frame_navigation" src="navigation.php” name=”frame_navigation” /> <?php echo __('phpMyAdmin is more friendly with a frames-capable browser.’); ?>
Thank you very much for guiding me to success! This is a very good tutorial.
thanks
Thanks, finding it interesting to work with php on iis, rather than Wamp stack or similar
thank you for this. Very helpful!
Thanks a lot :)
Thanks so much for this clear explanation. There are loads of sites that offer unstructured waffle. This page is beautifully written and structured. Thanks again
Hi, :)
I would like to know how will I install phpmyadmin if i have another website registered to iis? I got an existing website in my iis and when I tried to install it with phpmyadmin (c:/inetpub/wwwroot/php; port:1880) — cant connect. :( it says “Cannot verify access to path C:inetpubwwwrootphp” and tried to go to the address bar of my browser, still having an error. :/ Can anyone help me with this? Thank you very much!