Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

How often do you need to reapply this?


Set it in your environment / shell startup files (.bash_profile, for example)

  export POWERSHELL_TELEMETRY_OPTOUT=1
and, in theory, you should be good to go (unless/until Microsoft decides to change things up).

---

After logging out and logging in again, you can verify this has been set properly by simply running

  echo $POWERSHELL_TELEMETRY_OPTOUT
in your shell (it should simply output "1").


From the Microsoft website: “The telemetry reporting can be disabled by setting the environment variable POWERSHELL_TELEMETRY_OPTOUT to true, yes, or 1. This should not be done in your profile, as PowerShell reads this value from your system before executing your profile.”


It's not supposed to go into the PowerShell $profile; .bash_profile which later starts pwsh should be fine.




Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: