IoT Isolation for Homelabs: VLANs, Firewall Rules, and mDNS

IoT isolation has a bad reputation because the first version often breaks everything. The smart TV vanishes from casting. The speaker stops responding. The printer is suddenly a mystery box. The family is unimpressed. Then the firewall rules get opened too wide and the network becomes flat again, just with more VLAN names.

The better pattern is to isolate by default and add small, documented exceptions. That matches the way security guidance talks about IoT. NIST IR 8259A focuses on device cybersecurity capabilities, CISA has consumer guidance on securing IoT devices, and ETSI EN 303 645 gives baseline consumer IoT security expectations. At home, your network is the enforcement layer you actually control.

Design principle: IoT devices should reach the internet and the controllers they need. They should not have broad access to trusted clients, servers, or management gear.

Reference diagram
IoT Isolation With Usable Exceptions
The goal is not to break smart devices. The goal is to stop them from becoming a flat-LAN bridge.
Trusted VLAN phones / laptops IoT VLAN TVs / plugs / cams Controller Home Assistant DNS / NTP approved basics Media Devices cast targets Internet vendor cloud Deny IoT to LAN by default. Add tiny exceptions for controllers, DNS, NTP, and casting.mDNS discovery is not the same as full LAN access.
Inventory first
Group devices by behavior: cloud-only, controller-based, camera, media, and admin.
Default deny
IoT should not initiate broad access into trusted or management VLANs.
Scoped discovery
Use mDNS only for the services that need it.

Classify Devices Before Moving Them

Device TypeExamplesNetwork NeedTypical Policy
Cloud-only IoTSmart plugs, appliances, bulbsInternet, DNS, NTPNo LAN access.
Controller-based IoTHome Assistant devices, Zigbee bridgesController IP and sometimes mDNSAllow only controller paths.
Media / castingTVs, speakers, streaming boxesInternet, DNS, mDNS, selected controller accessAllow scoped discovery and media control.
CamerasIP cameras, doorbellsNVR or controller, maybe internet if cloud-requiredPrefer camera-to-NVR only where possible.
PrintersNetwork printersTrusted clients to printer, not printer to LANAllow client-initiated print protocols only.

Recommended VLANs

  • Trusted VLAN for phones, laptops, and daily computers.
  • IoT VLAN for smart devices that do not deserve trusted LAN membership.
  • Media VLAN only if you need to separate TVs and speakers from general IoT.
  • Camera VLAN if cameras or NVR traffic deserve their own rules and retention policy.
  • Management VLAN for network gear, hypervisors, and admin interfaces.

Firewall Baseline

RuleSourceDestinationPortsAction
IoT to DNSIoT VLANInternal DNS53 TCP/UDPAllow
IoT to NTPIoT VLANGateway or NTP server123 UDPAllow
IoT to internetIoT VLANWANRequired outboundAllow
IoT to trusted LANIoT VLANTrusted VLANAnyDeny and log
IoT to managementIoT VLANManagement VLANAnyDeny and log
Trusted to IoTTrusted VLANSelected IoT devicesRequired app portsAllow where needed
IoT to controllerIoT VLANHome Assistant / NVRSpecific portsAllow only as documented

mDNS Without Giving Up

mDNS is why devices can discover each other without central DNS, and RFC 6762 defines that behavior. Across VLANs, you need a gateway or controller feature that can relay or reflect selected discovery traffic. The important distinction is this: discovery is not permission. Letting a phone discover a speaker does not mean every IoT device should reach every trusted client.

  1. Enable mDNS reflection only between the VLANs that need discovery.
  2. Test one workflow at a time: phone to speaker, phone to TV, Home Assistant to device, client to printer.
  3. Add firewall allows for the actual control or media ports after discovery works.
  4. Log denials during testing so you can see what the app is trying to do.
  5. Remove temporary broad rules after testing.

Home Assistant Pattern

For Home Assistant, put the controller in a server or controller VLAN. Let it reach IoT devices that require local polling or control. Let trusted phones reach Home Assistant. Deny IoT devices from initiating broad access into trusted clients or management. This preserves automation without turning the IoT VLAN into a hidden bypass.

Validation Checklist

  • An IoT device gets the IoT VLAN address and correct DNS.
  • The IoT device reaches the internet if its function requires cloud access.
  • The IoT device cannot reach laptop shares, NAS admin, hypervisor UI, or network gear.
  • Trusted phones can control approved media devices.
  • Home Assistant or NVR can reach the devices it manages.
  • Firewall logs show blocked lateral attempts without breaking expected use.

Useful Gear And Buyer Notes

Affiliate disclosure: As an Amazon Associate, TechGeeks may earn from qualifying purchases. The product links below are buying references, not a requirement to buy a specific brand or seller. Verify compatibility, seller quality, warranty, and current specs before ordering.

NeedGood ChoiceWhy It FitsAffiliate Link
Segmentation gatewayUniFi Cloud Gateway Ultra or MaxGood fit for VLANs, firewall rules, and AP-integrated IoT SSIDs.Amazon: UCG Ultra
Amazon: UCG Max No Storage
Managed switchTP-Link TL-SG2008P or UniFi switchNeeded for VLAN-aware wired IoT, APs, and PoE devices.Amazon: TP-Link TL-SG2008P
Smart-home controllerHome Assistant Green or mini PCKeeps automations local and gives you a clear controller target for firewall rules.Search Amazon: Home Assistant Green
Radio coordinatorZigbee or Z-Wave coordinatorMoves some devices off Wi-Fi and into a local controller model.Search Amazon: Zigbee coordinator Home Assistant
Cable and labelsShort Cat6 patch cables and labelerIoT networks get messy fast without port and device labels.Amazon: Cable Matters 1ft Cat6 10-pack
Amazon: Brother PTD220 label maker

Common Mistakes

  • Moving every smart device at once and then not knowing what broke.
  • Allowing IoT to trusted LAN because one casting workflow failed.
  • Forgetting DNS and NTP, then blaming the device.
  • Treating mDNS as scary magic instead of scoped discovery.
  • Letting cameras initiate traffic to everything instead of only the NVR or cloud path they need.

References

Final Thought

The win is not a perfectly pure IoT VLAN. The win is a smart-home network that still works while giving untrusted devices fewer places to wander. Start strict, add small exceptions, keep logs, and document why every exception exists.

This article is part of the TechGeeks homelab foundation series. The series is designed to build practical home infrastructure in the right order: remote access, segmentation, exposure control, DNS, IoT isolation, and recoverable backups.

Need help applying this?

Bring TechGeeks into the real environment.

If you are working through this on a live network, WordPress site, Linux server, AI workflow, or PisoWiFi deployment, send the context and we can help turn it into a practical plan.

Request helpGet field notesRecommended gear

Leave a Reply

Your email address will not be published. Required fields are marked *