How to Kill a Process If It Is Running in PowerShell?

You’re working on your computer, and a program freezes. Or maybe you need to stop a process before running a script. Whatever the reason, you would like to know how to kill a process in PowerShell if it is running. I’ll walk you through everything you need to know about killing processes in PowerShell if … Read more

How to Clear PowerShell History (And Why You Might Want To)

Clear PowerShell History

If you’ve been using PowerShell for a while, you’ve probably noticed it remembers every command you’ve typed. That’s usually handy—until it’s not. Maybe you accidentally typed a password in plain text. Or perhaps your history is so cluttered you can’t find anything useful anymore. Whatever the reason, clearing your PowerShell history is simpler than you … Read more

How to Get All Properties of an Object in PowerShell

Get All Properties of an Object in PowerShell

If you’ve been working with PowerShell for a while, you’ve probably run into situations where you need to see what properties an object has. Today, I’m going to walk you through everything you need to know about getting all properties of an object in PowerShell. We will see different methods with examples. When you run … Read more

How to Check if a Port is Open Using PowerShell?

powershell check if port is open

Hey there! Today I’m going to show you how to check if a port is open using PowerShell. This is one of those tasks that sounds technical, but it’s actually pretty straightforward once you know the right PowerShell commands. Whether you’re troubleshooting a network issue, setting up a new server, or just trying to figure … Read more

How to Find and Remove Stale Computer Objects in Active Directory with PowerShell?

If you manage Active Directory, you’ve probably noticed that computer accounts tend to pile up over time. Machines get replaced, users switch laptops, or systems are decommissioned — but those old computer objects? They often stick around in AD. These stale computer accounts aren’t just clutter. They can create security vulnerabilities (imagine an attacker reactivating … Read more

PowerShell For Loop 1 to 10 [With Examples]

PowerShell For Loop 1 to 10

I will explain a fundamental topic today, PowerShell for loop 1 to 10. The simple “loop from 1 to 10” is the perfect starting point because it teaches you the fundamental pattern you’ll use to automate countless repetitive tasks. Once you understand this basic structure, you’ll be able to adapt it to loop through anything: … Read more

How to Break Out of ForEach Loops in PowerShell?

Break Out of ForEach Loops in PowerShell

Suppose, you’re looping through thousands of files, user accounts, or log entries, searching for one specific item. Once you find it, why keep looping through the rest? That’s where breaking out of a foreach loop becomes very useful. It saves processing time, makes your scripts more efficient, and prevents unnecessary work. In this tutorial, I … Read more

How to Find Unquoted Service Paths with PowerShell?

If you manage Windows systems—whether you’re a sysadmin, security analyst, or just someone who wants to keep their environment secure—there’s a surprisingly common vulnerability hiding in plain sight: unquoted service paths. In this tutorial, I will explain how to find unquoted service paths with PowerShell using different methods. But let us first understand why it … Read more

Why Does Windows PowerShell Keep Popping Up?

Why Does Windows PowerShell Keep Popping Up

If you’ve ever been working peacefully on your Windows PC only to have a blue PowerShell window suddenly flash on your screen—sometimes repeatedly—you know how frustrating it can be. Not only is it annoying, but it can also make you worry: “Is my computer infected? Did I break something?” The good news? We can fix … Read more

PowerShell Find Location of Executable

PowerShell Find Location of Executable

If you’re working on Windows and using PowerShell, you’ve likely encountered situations where you need to find the exact location of an executable file on your system. This tutorial will guide you through multiple methods to find the location of an executable using PowerShell. I will explain step by step. When you type a command … Read more

100 PowerShell cmdlets download free

100 POWERSHELL CMDLETS E-BOOK

FREE Download an eBook that contains 100 PowerShell cmdlets with complete script and examples.