OPC UA status codes: structure and the codes you meet most
How a 32-bit StatusCode is built (severity, sub-code, info bits), what Good, Uncertain and Bad mean for values, and a table of frequent codes.
Bit layout
A StatusCode is a UInt32 (OPC 10000-4, StatusCode):
| Bits | Field | Meaning |
|---|---|---|
| 31–30 | Severity | 00 Good, 01 Uncertain, 10 Bad |
| 27–16 | SubCode | The specific condition (e.g. NodeIdUnknown) |
| 15 | StructureChanged | Structure of the value changed — re-read metadata |
| 14 | SemanticsChanged | Meaning (units, range) changed |
| 11–10 | InfoType | 01 = the low bits describe a data value |
| 9–8 | LimitBits | 00 none, 01 low, 10 high, 11 constant |
| 7 | Overflow | Queue overflow in a monitored item — values were lost |
| 4–0 | Historian bits | Raw / calculated / interpolated, partial, extra data, multi-value |
So 0x80340000 = Bad + SubCode 0x034 (NodeIdUnknown). Codes in the official list have the low 16 bits zero; a server may add info bits on top, e.g. a Good value at the high limit.
Status of a value
Every value read or received in a subscription carries a status:
- Good — the value can be used.
- Uncertain — usable with care (
UncertainLastUsableValue: the source stopped updating;UncertainSensorNotAccurate). - Bad — not a measurement (
BadWaitingForInitialData,BadNoCommunication,BadSensorFailure). Do not use it in control or calculations.
Frequent codes
| Code | Hex | Usual cause |
|---|---|---|
| BadNodeIdUnknown | 0x80340000 | Wrong NodeId or namespace index |
| BadNotReadable / BadNotWritable | 0x803A0000 / 0x803B0000 | AccessLevel forbids the operation |
| BadUserAccessDenied | 0x801F0000 | The user lacks permission |
| BadTypeMismatch | 0x80740000 | Written value has a different data type (Int16 vs Int32, Float vs Double) |
| BadOutOfRange | 0x803C0000 | Value outside the allowed range |
| BadTimeout | 0x800A0000 | Request took too long |
| BadCommunicationError | 0x80050000 | Low-level transport problem |
| BadCertificateUntrusted | 0x801A0000 | Certificate not trusted |
| BadTooManySessions | 0x80560000 | Server session limit reached |
| UncertainLastUsableValue | 0x40900000 | Source stopped updating |
Use the status code decoder to look up any value.
Connections
Open in Knowledge Graph →Loading the map…
Sources
- OPC 10000-4 Part 4: Services (v1.05) — OPC Foundation
- UA-Nodeset: StatusCode.csv (official list of status codes) — OPC Foundation
- OPC 10000-6 Part 6: Mappings (v1.05) — OPC Foundation
Updated 2026-10-02