Tuesday, 12 February 2013

Error occurred in deployment step ‘Recycle IIS Application Pool’ – SharePoint 2013 and Visual studio 2012

If you working on a SharePoint 2013 Visual Studio 2012 project. And after you have created a Visual web part then you tried to deploy to SharePoint Site collection. May you got the following error:

Error occurred in deployment step 'Recycle IIS Application Pool': Cannot connect to the SharePoint site: http://servername/. Make sure that this is a valid URL and the SharePoint site is running on the local computer. If you moved this project to a new computer or if the URL of the SharePoint site has changed since you created the project, update the Site URL property of the project.

  • First you should open the web site and check wither it is opening in the browser or not. If it’s not work then you should check the SharePoint servers are running.
  • Second, If the web site is open successfully then you should Restart visual studio.
  • Finally, if the site is open successfully and you had Restarted visual studio. then you should check if the  current user on the web content database is owner.  If not then add the current user to the web content database with owner role.


  1. That error also occurs if the port of the admin site has changed (e.g. if you ran the repair feature of the install)

  2. Thank you, the third step was my solution.

  3. You must check other scenarios as well along with you mentioned above. Read all scenarios here: http://praveenbattula.blogspot.in/2013/07/error-occurred-in-deployment-step.html

  4. I got this error, and he stated that he "forgot to give my account sysadmin rights on server". Hopefully this is another scenario to consider.

  5. I got this error when I changed my password. Logging out and back in resolved the issue.