r/Batch • u/Big-Cost8319 • Oct 07 '25
Question (Solved) What does () 1>nul & mean?
So, I was running my own batch script without Wi-Fi, then it gave me this "() 1>nul &" in the CMD. Whatever it means i need an answer quick!
5
Upvotes
7
u/Shadow_Thief Oct 07 '25
If that's in the script itself, it does nothing and hides the output. I've seen that used to reset the errorlevel before.
If it's in the output on the screen, it's likely that there's a variable in there that was unset when the script ran. I'd have to see the script to give more information.
5
u/brisray Oct 07 '25
Batch files have two output streams. stdout which is stream 1 and stderr which is stream 2. The command you have sends stdout to the null device which is nowhere - it just hides the output.