How-to
Remote HMI access with dynamic DNS and a VPN
Short answer
Never port-forward an HMI to the public internet. Reach Vijeo Design Air through a VPN that ends inside the plant network, and let dynamic DNS track the site's changing public address so the VPN client always finds the endpoint. The app itself keeps using the HMI's private IP address on the Wi-Fi and VPN paths alike.
On this page
- Why does Vijeo Design Air work on the plant Wi-Fi but fail from home?
- Should I port-forward the Magelis HMI to the internet instead?
- Can this site accept an inbound VPN connection at all?
- How do I set up dynamic DNS for a changing public IP?
- How do I route the VPN tunnel to the HMI's subnet?
- How do I test the whole path before trusting it?
- How do I keep the remote path restricted to the people who need it?
- Questions asked
Vijeo Design Air opens a Magelis HMI across the plant's local network with nothing but the HMI's private IP address, and that is exactly how it should open from off-site too — through a VPN tunnel that ends inside the plant network. Never port-forward the HMI's remote service to the internet: it exposes operating commands to every address online, and it breaks the day the site's public address changes. Dynamic DNS has a real but narrow job on this path: it keeps the VPN endpoint's hostname pointed at a changing public address, and it grants no access by itself. The order of work below covers the local baseline, the inbound-endpoint check with its arithmetic, the dynamic DNS setup, the tunnel route to the HMI subnet, the external test, and the access controls that keep the path restricted.
Why does Vijeo Design Air work on the plant Wi-Fi but fail from home? #
Because on the plant Wi-Fi your tablet and the HMI share one routed network, the private IP address you type into the app is directly reachable, while a home or cellular connection is a different network with no route back to that address until you build one.
On Wi-Fi the tablet, the access point and the HMI are one network; from home, packets must cross the internet, enter through the site's public address, and arrive at a private address that only exists behind the plant's router. That arrival path is the whole project. Before touching the internet side, nail the local baseline:
- Read the HMI's IP address, subnet mask and default gateway from its network configuration, and fix the address with a static setting or a DHCP reservation, because an address handed to a different device looks exactly like a dead HMI — the PC-side twin of that failure is covered in why a PC fails to reach an HMI when Wi-Fi owns its address.
- If the HMI joins Wi-Fi at all, it does so through a wireless router or access point; the vendor documents that a USB wireless adapter is not the way onto the network.
- Enable the remote service on the engineering PC: in Vijeo Designer, click the Target node in the Project tab and expand the Remote Management node in the Property Inspector, leaving authentication switched on.
- Open one local session and keep it as your reference — it proves the app and this HMI talk, and it tests nothing about the internet path.
A working local session proves the app and the HMI speak. It says nothing about the site's inbound firewall, the upstream provider arrangement, or routing from your couch — those are the next two checks.
Should I port-forward the Magelis HMI to the internet instead? #
No — a forwarded port exposes the HMI's operator commands to every address on the internet, it is probed by mass scanners continuously, and it still breaks when the public address changes, so put a VPN endpoint in front and forward nothing but the tunnel.
The tunnel gives the app the same private path it already has on Wi-Fi, so the project needs no second address and no exposed service: with the tunnel up, plant addresses are simply local. Enable the service's authentication as well — the vendor documents running Design Air without security, and a target in that state must never meet the internet except through an authenticated tunnel, which is the second reason the tunnel, not a port map, carries the service. One safety line: a remote session can start machinery, so the panel's emergency-stop chain and local operating rules must stay effective no matter who is connected or from where.
Can this site accept an inbound VPN connection at all? #
Compare the address on the router's WAN port with the public address the internet sees: if they match, that router owns the site's real endpoint and an inbound VPN is possible; if they differ, a translation boundary above it blocks inbound connections for everyone.
Worked example: the router's status page reads 100.64.28.51 on the WAN port, and a public-address lookup from the same connection returns 203.0.113.44. The range 100.64.0.0/10 runs from 100.64.0.0 to 100.127.255.255, and 100.64.28.51 falls between those bounds, so the WAN port carries carrier-grade NAT space — the provider, not the customer, owns the router that faces the internet. A dynamic DNS record on this router would publish 203.0.113.44 while the router listens on 100.64.28.51, so inbound connections arrive at the provider and stop there.
Decision: when the WAN reading sits inside 100.64.0.0/10, or when a second router above yours holds the public address, no port-forward and no hostname on the shop router can ever work — either get a routable address from the provider, or flip the design to outbound-initiated VPN, where the plant dials out to a gateway and nothing inbound is required. When the two readings match, the router owns the real endpoint and the setup in the next section applies to it directly.
Reaching a private-IP device from a public-side client through a router is one problem whether the target is an HMI or a controller; the walk-through of SLC 500 private-to-public communication through a router covers the translation mechanics end to end.
| What the two readings show | What it means | Where dynamic DNS belongs |
|---|---|---|
| WAN equals the public address | The router owns the real endpoint | On that router, watching its WAN port |
| WAN inside 100.64.0.0/10 | Carrier-grade NAT upstream | Nowhere on this router — change the design |
| Another router holds the public address | Double NAT hides the traffic | On whichever box truly owns the address, if one does |
| The public address changes between checks | A saved numeric endpoint goes stale | On the owning endpoint, always |
How do I set up dynamic DNS for a changing public IP? #
Dynamic DNS keeps a hostname pointed at the site's current public address, so the VPN client dials plant-line-1.ddns.example instead of a number that goes stale; set it up on whichever device actually owns the public address, and only when that address changes.
DDNS is name-to-address mapping that follows a changing address; it opens no port and grants no access, because the tunnel does the access and the name only finds the door. Set it up in this order:
- Confirm the address actually changes: read the provider contract or watch the router's WAN page across several weeks. A static public address makes the hostname optional — enter the address directly as the VPN endpoint and stop here.
- Choose a provider the endpoint supports: open the router or VPN gateway's DDNS settings and pick from the providers it lists, so the updater is built into the box that sees the address.
- Create one hostname — plant-line-1.ddns.example works as well as any — and complete any account confirmation the provider requires before counting the record as live.
- Configure exactly one updater: provider name, hostname and update credentials on that same device. A second updater on another box fights the first and can trip the provider's abuse limits.
- Verify from outside: on a phone using mobile data, resolve the hostname and compare it with the site's current public address; a mismatch means a stale record or an updater publishing the wrong interface.
- Enter the hostname, never a number, as the VPN connection's endpoint on every remote device.
Two limits to plan around: resolver caches keep serving the old record for a while after a change, and the change itself interrupts any session that was already open.
How do I route the VPN tunnel to the HMI's subnet? #
The tunnel must list the HMI's subnet in its permitted networks and carry the replies back, because a client sitting on 192.168.1.0/24 at home cannot reach a plant HMI on the same range — the app sends those packets to the local printer instead.
- Add the HMI's subnet to the tunnel's permitted networks on the VPN gateway; the most common failure in this whole design is a tunnel that connects while carrying no route to the plant LAN.
- Permit the HMI's remote service from the VPN client subnet to the one HMI on any internal firewall, taking the protocol and port from the documentation for the installed target rather than a number copied from a forum.
- Check the return path: the HMI's default gateway must send replies toward the VPN client subnet, or the VPN gateway must translate client traffic to its own address. Confirm traffic in both directions, because a one-way ping proves nothing.
- Worked overlap example: the engineer's home office sits on 192.168.1.0/24 and the plant HMI lives at 192.168.1.50. The app's packets to 192.168.1.50 go to the home printer and the session times out with the tunnel perfectly up. Pick the VPN client pool from 10.0.0.0/8 — 10.213.50.0/24 as an example — and if the plant itself uses 192.168.0.0/24 or 192.168.1.0/24, the two ranges home routers hand out most often, plan to renumber the machine network or pin routes on every client, because the overlap will find you.
How do I test the whole path before trusting it? #
Test from mobile data, never from the plant Wi-Fi, because the local network can satisfy the app through its own switch and hide every routing mistake; the tunnel must connect by hostname and the app must then open the HMI by its private IP address.
- Turn off Wi-Fi and connect the phone or laptop on cellular, so nothing local can answer for the plant.
- Connect the VPN and confirm it dialed the hostname: the client's status or route display should show the plant subnet riding the tunnel.
- Open Vijeo Design Air, enter the HMI's private IP exactly as recorded in the Wi-Fi baseline, and wait for live values on screen — that is the pass mark, because the app renders the HMI's own project.
- If the tunnel connects and the app times out, walk the chain in order: hostname stale (updater status), route missing (permitted networks), firewall drop (service rule), return path dead (gateway or NAT on the VPN gateway).
- If the target serves a browser-based WebGate client, test it over the same tunnel the same way.
- A session that worked for weeks and now dies mid-shift usually means the public address changed; reconnect by hostname and read the updater's log against the failure window.
How do I keep the remote path restricted to the people who need it? #
Give every engineer a personal VPN credential tied to the customer's approval, decide in writing whether a session may operate the machine or only watch, and switch the credential off when the project ends; a shared login makes the audit trail worthless when something moves unexpectedly.
On internal firewalls, scope the HMI's service rule to the VPN client subnet and the single HMI, so a compromised client reaches one device instead of the plant. Log tunnel sessions if the gateway supports it, because investigations that start with nobody was on site end there. Where the customer wants a strictly hands-off session, the same restriction exists for remote desktop sessions in read-only remote HMI access over RDP, and the intent transfers directly to this path. Decision, end to end: tunnel only, hostname on the endpoint that owns the public address, private IP in the app, one credential per engineer — that is the entire design.
Questions asked
Does a free dynamic DNS service work for this?
Yes, in many cases, because the hostname only needs to track one changing address. Before relying on one, confirm the router or gateway lists that provider among its supported update methods, complete any account confirmation the provider requires, and check inactivity-expiration terms — a lapsed record silently strands every remote session at the next address change.
What happens to an open session when the site's public address changes?
The tunnel drops and the app loses its connection while nothing at the HMI changes. Reconnect from the client, which resolves the hostname again and reaches the site's new address. Resolver caches can serve the old record for a while, so a client that refuses to reconnect deserves one retry after a few minutes before you start troubleshooting the plant.
Which address goes into the app once the tunnel is up?
The HMI's private IP address, exactly the value you use on the plant Wi-Fi, because the tunnel makes the plant subnet local to the client. Enter anything else only if the documentation for the installed target names another supported method, and never enter the VPN endpoint's hostname into the app itself.
Who should own the dynamic DNS account and hostname?
The plant, not the integrator. Register the hostname in the customer's own account, hand over the update credentials, and record both in the site documentation. A hostname owned by a personal account stops updating when that engineer moves on, and the first address change afterwards takes remote access down with it.