Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I would like to do this because I have a half installed service because of installation failure which is just there, non-functioning.

How can I delete the Windows service using the command line?

share|improve this question

migrated from Apr 28 '10 at 10:57

This question came from our site for professional and enthusiast programmers.

NOTE: You'll likely need an elevated command prompt (right click => "Run as Administrator") to execute this command

the sc command is what you want, specifically sc delete

C:\Users\Jeff>sc delete
        Deletes a service entry from the registry.
        If the service is running, or another process has an
        open handle to the service, the service is simply marked
        for deletion.
        sc  delete [service name]
share|improve this answer
If you're in powershell, you'll want to make sure to type sc.exe because sc in powershell gets you the Set-Content cmdlet which will quietly look like it might have worked. – Andrew Sep 9 '15 at 16:00

We need to stop the service before deleting it from registry.

sc stop [Service name]
sc delete [service name]

Run Command prompt as an administrator and execute above commands.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.