How to Enable or Disable guest account

by admin on March 31, 2013

To find out if guest account is enabled on your computer, you can run the below command

net user guest | findstr /C:"active"


c:\>net user guest | findstr /C:"active"
Account active               No

To enable guest account from command prompt:

Open elevated administrator command prompt and run the below command.

net user guest /active:yes


C:\>net user guest | findstr /C:"active"
Account active               No
C:\>net user guest /active:yes
The command completed successfully.
C:\>net user guest | findstr /C:"active"
Account active               Yes


To disable guest account:

net user guest /active:no

The above commands would work on Windows 7, Windows 8 and also on older versions like XP, Server 2003 etc.

Alternatively, we can enable or disable guest account from GUI using the user management console. Run the command ‘lusrmgr.msc’ from Run window, enter administrator credentials and go to the node ‘Users’ in the console. Open the guest account properties and then select / unselect the check button ‘Account is disabled’.

Enable or disable guest account on Windows 7

{ 8 comments… read them below or add one }

Paul April 12, 2013 at 2:18 pm

Good tip. Helped me to enable guest account on windows 7 machines from a batch file.


Rikesh April 14, 2013 at 2:15 pm

Thanks. I could disable guest account from cmd on my windows 8 system.


Mike November 10, 2013 at 7:04 am

I am getting the below error when I tried this command.

c:\>net user guest /active:yes
System error 5 has occurred.
Access is denied.


Adam November 11, 2013 at 9:59 pm

Mike, you will want to run CMD as an elevated user, right click and press “Run as Administrator”.

Moe July 24, 2014 at 12:30 am

you are using command prompt as a non-admin user, as Adam said, you can use “Run as Administrator” or open your administrator account and do it.

Rita March 1, 2014 at 10:02 pm

Good evening!

I’m having the same problem as Mike here, though i did run CMD as admin.

Is there any way to bypass that system error and forcefully deactivate the guest acc?<



mostafa January 22, 2015 at 5:02 pm

Thank you very much for your help


William Underhill August 18, 2015 at 5:44 am

I’ve tried the cmd line version and it says the account is active, but when I log off then try to log back in, it’s not an available option. Likewise I tried using the lusrmgr.msc approach, and got the following message:

(X) Local Users and Groups
This snapin may not be used with this edition of Windows 10. To manage user account for this computer, use the User Accounts Tool in the Control Panel.

The problem is that the Guest account is not LISTED in the User Accounts Tool…

OS: Win 10 Home (free upgrade from Win 7 Home Premium), under local account because I REFUSE to make it easier for MS to snoop in my computer.

At this point I’m thinking seriously of reverting to Win 7. At least THERE I can have a Guest account if I feel like it, and not have to jump through insane hoops…


Leave a Comment

Previous post:

Next post: