Change Windows Lockscreen
You can change the background of the Windows lockscreen with this Powershell snippet. Via the search bar open a new Administrator Powershell Window and paste the Code down below or download it here.
IMPORATNT: you need to change the path to your Image !!!
# Powershell code to change the LockScreen on Windows 10
# needs Admin rights
$imgPath = "C:\Users\schueler\Downloads\WhatsApp Bild 2025-10-17 um 13.03.03_78d12b26.jpg"
$code = @"
using System.Runtime.InteropServices;
public class LockScreen {
[DllImport("user32.dll", SetLastError = true)]
public static extern bool SystemParametersInfo(int uAction, int uParam, string lpvParam, int fuWinIni);
}
"@
Add-Type $code
$RegPath = "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\PersonalizationCSP"
New-Item -Path $RegPath -Force | Out-Null
Set-ItemProperty -Path $RegPath -Name "LockScreenImagePath" -Value $imgPath
Please give credit for republishing