Skip to content

Restart Windows Service

Restart a Windows service by stopping it and then starting it again

Required

The name of the Windows Service to restart

Required — Default: 60

Maximum wait time in seconds for each of the stop and start operations

  • Category: Windows service
  • Brick ID: Windows-Service-Restart
{
"category": "windowsService",
"description": "Restart a Windows service by stopping it and then starting it again",
"developerVendor": "CapaSystems A/S",
"displayName": null,
"id": "Windows-Service-Restart",
"name": "Restart Windows Service",
"parameters": [
{
"allowManualInput": false,
"defaultValue": "",
"defaultValueObject": null,
"description": "The name of the Windows Service to restart",
"id": "ServiceName",
"name": "Windows service name",
"regExValidation": "",
"required": true,
"type": "TextBox",
"value": null,
"values": [],
"valuesObject": null
},
{
"allowManualInput": false,
"defaultValue": "60",
"defaultValueObject": null,
"description": "Maximum wait time in seconds for each of the stop and start operations",
"id": "MaxTimeOut",
"name": "Timeout",
"regExValidation": "",
"required": true,
"type": "Integer",
"value": null,
"values": [],
"valuesObject": null
}
],
"powershell": {
"base64Encoded": true,
"function": "RnVuY3Rpb2..."
},
"type": "powerbrick",
"version": "2026.9.1.1"
}