Sensorclouds
Devices

Device Status

How Sensorclouds decides whether a device is online or offline

Every device shows a connection status:

StatusIndicatorMeaning
ONLINEGreen, pulsingThe device is connected or has reported recently
OFFLINERedThe device disconnected or has been silent too long
UNKNOWNGreyNo status yet, typically a device that has never connected

How status is detected

Sensorclouds combines two signals.

1. Status messages (Last Will)

The device tells the platform when it connects, and the broker tells the platform when it drops:

  • On connect, the device publishes {"status": "online"} to its /status topic.
  • When connecting, the device registers a Last Will message {"status": "offline"} on the same topic.
  • If the connection drops unexpectedly, the broker publishes the Last Will automatically, and the device goes OFFLINE within moments.

See Connecting Your Device for the settings.

2. Message activity

Every telemetry message the device sends counts as a sign of life. If no message arrives for 1.5 × the profile's keep-alive (90 seconds with the default keep-alive of 60 seconds), the device is marked OFFLINE. It goes back to ONLINE with its next message.

If your device reports less often than that, for example once every 5 minutes, it will flip to OFFLINE between messages. Raise the profile's keep-alive to more than your reporting interval. See MQTT Settings.

Device reports every…Set keep-alive to at least…
10–30 seconds60 seconds (default)
1 minute60–90 seconds
5 minutes300 seconds

Where status appears

  • Device lists, as colored dots
  • The workspace home page, with online/offline counts
  • Application overviews
  • Indicator widgets in Staleness mode
  • Notifications and integrations (Device online / Device offline events)

Troubleshooting

ProblemLikely causeFix
Flips between ONLINE and OFFLINEIt reports less often than 1.5 × keep-aliveRaise the profile's keep-alive
Shows ONLINE after being unplugged for a whileNo Last Will configured, so it goes offline only when the activity window expiresConfigure the Last Will
Stays UNKNOWNIt has never connected successfullySee Connection Troubleshooting

Next Steps

On this page