sticky
You cannot bypass the UAC prompt

    General discussion

  • We get a question like this at least once per week:

    How can I bypass the UAC prompt when running a program or a script?

    The answer to this question is that you cannot bypass the UAC prompt, and this is by design.

    Please read the following FAQ for the reasons why:

    FAQ: Why can't I bypass the UAC prompt?

    The only way to run a program that requires administrative access (elevation) is to use Run as administrator (either by right-clicking or or the shell runas verb in a script). You can also schedule the program to run with highest privileges, but doing so requires administrative permissions already and thus does not constitute bypassing the UAC prompt.

    The runas command starts a program with alternate credentials, but the program is not started as administrator (elevated). In other words, you cannot use the runas command to bypass the UAC prompt either.

    You cannot use the PsExec utility to bypass the UAC prompt either, because it installs a driver and thus must be run elevated to begin with.

    Disabling UAC is not recommended for the reasons stated in the FAQ.


    -- Bill Stewart [Bill_Stewart]


    Monday, December 29, 2014 7:03 PM
    Moderator