Matterbridge Logo   Matterbridge Task Scheduler configuration (Windows)

npm version npm downloads Docker Version Docker Pulls Node.js CI CodeQL codecov styled with prettier linted with eslint TypeScript ESM matterbridge.io

powered by powered by powered by


Production configuration

Run matterbridge as a scheduled task with Task Scheduler (Windows)

This is the simplest setup on Windows.

It runs Matterbridge when the current user logs in and uses the standard directories:

Optional: cleanup all previous setups

schtasks /delete /tn "Matterbridge" /f
Remove-Item -Recurse -Force "$HOME\Matterbridge", "$HOME\.matterbridge", "$HOME\.mattercert" -ErrorAction SilentlyContinue
npm uninstall -g matterbridge

Verify node setup

Nvm is a development tool and is not supported for production.

node -v
npm -v

It should output something like:

v22.20.0
10.9.3

Check node path

where.exe node

It should output something like:

C:\Program Files\nodejs\node.exe

First create the Matterbridge directories and install matterbridge

This will create the required directories if they don't exist and install matterbridge globally for the current user.

New-Item -ItemType Directory -Force -Path "$HOME\Matterbridge", "$HOME\.matterbridge", "$HOME\.mattercert" | Out-Null
npm install -g matterbridge --omit=dev
where.exe matterbridge.cmd
matterbridge --version

Then create a scheduled task for Matterbridge

Run PowerShell as Administrator

$NodeExe = (where.exe node | Select-Object -First 1)
$MatterbridgeCmd = (where.exe matterbridge.cmd | Select-Object -First 1)
$MatterbridgeJs = Join-Path (Split-Path $MatterbridgeCmd -Parent) "node_modules\matterbridge\bin\matterbridge.js"
schtasks /create /f /tn "Matterbridge" /sc onlogon /delay 0000:30 /tr "`"$NodeExe`" `"$MatterbridgeJs`" --nosudo"

This will start Matterbridge 30 seconds after the current user logs in.

This setup starts Matterbridge once at logon. If Matterbridge exits, it stays stopped until the next logon or until you start it again manually.

You can configure and adapt the task on the Task Scheduler.

Start Matterbridge

schtasks /run /tn "Matterbridge"

Stop Matterbridge

Stop Matterbridge from the frontend.

To force stop use

schtasks /end /tn "Matterbridge"

Restart Matterbridge

Stop Matterbridge from the frontend.

schtasks /end /tn "Matterbridge"
schtasks /run /tn "Matterbridge"

Show Matterbridge status

schtasks /query /tn "Matterbridge" /v /fo list

Show Matterbridge status (only essentials)

schtasks /query /tn "Matterbridge" /v /fo list | findstr /I "TaskName Status Last Run Time Last Result"

Enable Matterbridge to start automatically on logon

schtasks /change /tn "Matterbridge" /enable

Disable Matterbridge from starting automatically on logon

schtasks /change /tn "Matterbridge" /disable

Optional: remove the scheduled task completely

Run PowerShell as Administrator

schtasks /delete /tn "Matterbridge" /f