I'm looking for a reliable way to show end users a popup or toast notification telling them that their computer needs to be restarted. Ideally, the notification would be delivered through Intune and could use a remediation script or another management method to check conditions such as system uptime. Has anyone implemented this successfully, and what approach has worked best in production?
5 Answers
The bigger issue is that Intune’s built-in restart behavior still isn’t as dependable as the old Configuration Manager experience. Users can dismiss or postpone the prompt, and devices that are shut down during the evening may never restart when expected. A scripted notification with repeated reminders and a clearly enforced deadline is usually more effective.
You can use an Intune remediation to check uptime and then display a message to the logged-in user when the threshold is reached. Just be careful about execution context: the detection can run as system, but the notification itself usually needs to run in the user session.
A Windows toast notification script is a solid starting point. There’s an older script from imab.dk that has been updated periodically and can be adapted for Intune notifications.
The PowerShell App Deployment Toolkit is another option if you need polished dialogs, countdowns, and restart deferrals. It takes more setup than a basic toast script, but it gives you much better control over the user experience.
Endpoint Analytics proactive remediations work well for this. Set the detection script to evaluate uptime or a pending restart condition, then have the remediation launch a user-facing notification. You can adjust the uptime threshold to match your maintenance policy.

That system-versus-user split is exactly what I want to test before rolling it out. I’d rather validate the behavior properly than spend a day troubleshooting a script that works in only one context.