---
title: "OPC UA to MQTT — ConnectMQ Edge OPC UA Client Connector | ConnectMQ"
description: "Subscribe to nodes of any OPC UA server — S7-1500, Beckhoff, B&R, KEPServerEX — with ConnectMQ Edge and publish only changes to MQTT over TLS as ISA-95 topics."
url: "https://connectmq.com/connectmq-edge/opc-ua-client/"
language: "en"
---

ConnectMQ Edge · OPC UA Client

# Any OPC UA server, connected to the cloud

Most modern PLCs, SCADA systems and gateways already speak OPC UA, but getting that data to the cloud securely still takes work. ConnectMQ Edge subscribes to any OPC UA server, transfers only changes and publishes them to your ConnectMQ broker as clean ISA-95 topics, ready for dashboards, alerts and the Digital Twin. It is also the way to bring optimized S7-1500 data blocks to the cloud.

-   opc.tcp:// · subscriptions
-   S7-1500, Beckhoff, B&R
-   KEPServerEX, other servers

[Try it free](https://app.connectmq.com/signup) [See pricing](https://connectmq.com/pricing/)

No card required

-   Siemens S7 PLCs
-   OMRON PLCs
-   Modbus meters
-   IEC 104 RTUs
-   IEC 61850 IEDs
-   OPC UA servers

**ConnectMQ Edge**Windows service`ISA-95 · JSON``offline buffer`SCADA / HMI · OPC UA :48010 · MQTT :1883

**ConnectMQ Cloud**`broker.connectmq.com`Dashboards · Alerts · Digital Twin · API

## Why connect OPC UA Client to ConnectMQ

### Only changes, no constant polling

Values arrive by subscription, so only changes travel from the server to Edge and on to ConnectMQ.

### Tags discovered for you

Point a device at a BrowseRoot with AutoCreateTags, and Edge creates a tag for every variable below that node.

### Secure from server to cloud

Sign or SignAndEncrypt with user login towards the server, MQTT over TLS (port 8883) to ConnectMQ, and an offline disk buffer in between.

## What it reads and does

-   Any OPC UA server: S7-1500, Beckhoff, B&R, KEPServerEX, another Edge
-   Subscriptions: only changed values are transferred
-   Nodes listed by NodeId or discovered below a BrowseRoot
-   SecurityMode Sign / SignAndEncrypt with user name and password
-   Optimized S7-1500 data blocks via the PLC’s OPC UA server

What arrives in ConnectMQ Cloud`connectmq/site1/production/line1/press/Press1/Pressure`

```
{ "value": 182.6, "quality": "good", "unit": "bar", "tag": "Pressure", "device": "Press1", "channel": "LineUa" }
```

## Up and running in three steps

1.  1
    
    ### Install ConnectMQ Edge
    
    Download Edge from your ConnectMQ account and sign in — the Windows service and desktop app come in one installer.
    
2.  2
    
    ### Add the OPC UA Client channel
    
    Pick the OPC UA Client template, enter the address of your device and the tags you need, and press Save and apply.
    
3.  3
    
    ### Use the data
    
    The tags appear in your ConnectMQ broker as ISA-95 topics, ready for dashboards, alerts and the Digital Twin.
    

## Where teams use it

### Optimized S7-1500 data

Read symbolic data blocks of S7-1500 PLCs through their built-in OPC UA server and use them in ConnectMQ dashboards and alerts.

### SCADA and KEPServerEX to the cloud

Bring tags you already have in KEPServerEX or another OPC UA server into ConnectMQ without touching the field devices.

### Multi-vendor lines

Combine Beckhoff, B&R and Siemens machines in one ISA-95 tree and compare them on the same dashboards.

## OPC UA Client: frequently asked questions

How do I send OPC UA data to MQTT?

Add an OPC UA Client channel in ConnectMQ Edge, enter the server’s endpoint URL (for example opc.tcp://192.168.1.50:4840) and, if required, a user name and password, then list the nodes as tags or let Edge browse them. Edge subscribes to the nodes and publishes the values to your ConnectMQ broker over MQTT and TLS (port 8883) in an ISA-95 topic tree.

Do I have to add every OPC UA node by hand?

No. Give a device "AutoCreateTags": true and a BrowseRoot (for example ns=3;s=Press1), and Edge creates a tag for every variable below that node; BrowseDepth sets how deep it browses. You can also list single nodes as tags, for example ns=3;s="DB\_Press"."Pressure" copied from UaExpert.

Does the OPC UA Client support encrypted connections?

Yes. Set SecurityMode to Sign or SignAndEncrypt and, if the server requires it, a user name and password. Then trust the Edge client certificate on the server; it is created in %ProgramData%\\ConnectMQ\\Edge\\pki-client\\own.

Technical details: step-by-step setup and example configuration

### Set it up step by step

1.  1
    
    Get the endpoint URL of the server (for example opc.tcp://192.168.1.50:4840) and, if required, a user name and password.
    
2.  2
    
    In ConnectMQ Edge, open Connectors in the left menu, click + Add channel and pick the OPC UA Client template.
    
3.  3
    
    The channel is added with sample addresses. In the editor on the right, change the endpoint URL, device settings and tags to match your equipment; Validate project checks the configuration.
    
4.  4
    
    Press Save and apply. The channel starts right away without restarting the service. Add as many channels as you need, including several of the same type.
    
5.  5
    
    Either list the nodes as tags (ns=3;s="DB\_Press"."Pressure", copied from UaExpert) or let Edge discover them: a device with "AutoCreateTags": true and a BrowseRoot creates a tag for every variable below that node.
    
6.  6
    
    With SecurityMode Sign or SignAndEncrypt, trust the Edge client certificate on the server. It is created in %ProgramData%\\ConnectMQ\\Edge\\pki-client\\own.
    
7.  7
    
    Check the result: on Overview, the devices show Reading data under Field devices, and problems (wrong address, timeout, rejected login) appear in the Last problem column. The values themselves are in Local OPC UA Server › Live tag values; details are in Windows Service Settings › Logs.
    
8.  8
    
    Open the ConnectMQ portal: the tags appear in the topic tree as <enterprise>/<site>/<area>/<line>/<cell>/<device>/<tag> with a JSON payload (value, quality, unit, timestamp), ready for dashboards, alerts and the Digital Twin.
    

Example configuration

```
{
  "Name": "LineUa",
  "Driver": "OpcUaClient",
  "Settings": {
    "EndpointUrl": "opc.tcp://192.168.1.50:4840",
    "SecurityMode": "SignAndEncrypt",
    "Username": "operator",
    "Password": "***"
  },
  "Devices": [
    {
      "Name": "Press1",
      "ScanRateMs": 500,
      "Tags": [
        { "Name": "Pressure", "Address": "ns=3;s=\"DB_Press\".\"Pressure\"", "Unit": "bar" }
      ]
    },
    {
      "Name": "AllVariables",
      "Settings": { "BrowseRoot": "ns=3;s=Press1", "BrowseDepth": 3, "AutoCreateTags": true }
    }
  ]
}
```

### Good to know

-   Values arrive by subscription, so only changes are transferred between the OPC UA server and Edge.
-   Optimized (symbolic) S7-1500 data blocks cannot be read with the Siemens S7 connector; read them through the S7-1500 OPC UA server with this connector instead.
-   If the connection fails with Sign or SignAndEncrypt, the server most likely does not trust the Edge client certificate yet. You find it in %ProgramData%\\ConnectMQ\\Edge\\pki-client\\own.

## Other connectors

[**Siemens S7**S7-1200/1500, S7-300/400, S7-200 SMART and LOGO! over ISO-on-TCPLearn more](https://connectmq.com/connectmq-edge/siemens-s7/) [**Modbus TCP / RTU**Energy meters, drives and PLCs over Modbus TCP, UDP or RS-485 RTULearn more](https://connectmq.com/connectmq-edge/modbus/) [**OMRON FINS / NJ-NX**CJ/CP/CS memory areas over FINS and NJ/NX variables by nameLearn more](https://connectmq.com/connectmq-edge/omron/) [**IEC 60870-5-104**RTUs and substation gateways as controlling station, port 2404Learn more](https://connectmq.com/connectmq-edge/iec-104/) [**IEC 61850 (MMS)**Protection relays, bay controllers and IEDs over MMS with SCL importLearn more](https://connectmq.com/connectmq-edge/iec-61850/) [**Sparkplug B**Ignition, Node-RED and Sparkplug gateways via the local brokerLearn more](https://connectmq.com/connectmq-edge/sparkplug-b/) [**Local OPC UA server**Every tag Edge collects on one OPC UA endpoint for SCADA and MESLearn more](https://connectmq.com/connectmq-edge/opc-ua-server/)

[ConnectMQ Edge](https://connectmq.com/connectmq-edge/)

## Connect your first PLC this week

Create your ConnectMQ account, download ConnectMQ Edge from the portal and add your first connector in minutes.

[Get started](https://app.connectmq.com/signup) [See pricing](https://connectmq.com/pricing/)

## Articles

[All articles](https://connectmq.com/blog/)

Industrial IoT

### [Sparkplug B and the Unified Namespace: Structuring Industrial IoT Data on MQTT](https://connectmq.com/blog/mqtt-sparkplug-b-unified-namespace/)

Sparkplug B gives industrial MQTT a strict session and payload model, while a Unified Namespace gives your plant data a single, readable home. Here is how they fit together, with topic design tips and live examples.

August 26, 20269 min read

Managed MQTT Cloud

### [How to Choose an IoT MQTT Broker: 12 Criteria and the Questions to Ask Your Vendor](https://connectmq.com/blog/how-to-choose-an-iot-mqtt-broker/)

A practical 12-point checklist for choosing an IoT MQTT broker, a table of questions to ask every vendor, and a five-minute hands-on test you can run against broker.connectmq.com.

September 21, 20269 min read

MQTT Security

### [MQTT Security Best Practices: A 12-Point Checklist for IoT Teams](https://connectmq.com/blog/mqtt-security-best-practices/)

A hands-on MQTT security checklist covering TLS, credentials, client IDs, topic design, payload validation, rate limits and certificate checks, plus how ConnectMQ handles each point.

September 28, 202611 min read
