# delete files older than x days using powershell

There may come a time when you want to delete files older than x days using powershell
You can do this via the following powershell code:

# Delete files older than x days
Get-ChildItem '\\path\to\backup\folder' -Recurse |
Remove-Item -Force