×

Create Account

Join us today and get started!

Continue with Google
or use email

6-digit security PIN (required for new accounts).

Need to sign in? Sign in

×

Sign In

Welcome back. Sign in to your account.

Continue with Google
or use email

Need to create an account? Create Account

VLANs Step-by-Step in UniFi OS

UniFi OS Guide

← Back to Resources

Hands-on walkthrough: create a VLAN network, SSID, switch port profile, and trunk to access points.

VLANs Step-by-Step in UniFi OS

Build a Guest VLAN from scratch — repeat the pattern for IoT, cameras, or voice.

Goal

  • Corporate stays on existing LAN/VLAN.
  • Guest WiFi on VLAN 20 with internet only — no access to printers or servers.

Step 1 — Create the network (VLAN)

  1. Settings → NetworksCreate new.
  2. Name: Guest, VLAN ID: 20.
  3. Gateway: your UniFi gateway (for DHCP on that VLAN).
  4. Enable DHCP with an appropriate range (e.g. 192.168.20.1/24).
  5. Save.

Step 2 — Create the WiFi SSID

  1. Settings → WiFiCreate new.
  2. Name: Company-Guest.
  3. Network: select Guest (VLAN 20).
  4. Security: WPA2/WPA3 personal with a strong password or portal.
  5. Enable Guest isolation / Block LAN to WLAN as available.
  6. Save.

Step 3 — Switch port profiles (if using UniFi switches)

  1. Settings → ProfilesSwitch ports (or Port Profiles).
  2. Ensure AP uplink ports are Trunk All or include VLAN 20 tagged.
  3. Access ports for printers/PCs stay on corporate VLAN untagged.

Step 4 — AP provisioning

  • APs must receive tagged VLAN 20 on their uplink (automatic when SSID maps to VLAN 20 on UniFi switches).
  • Third-party switches: configure AP ports as trunk with VLAN 20 allowed.

Step 5 — Firewall rules

  1. Settings → SecurityFirewall & Security (or Traffic Rules).
  2. Allow Guest → Internet.
  3. Deny Guest → Corporate subnets (RFC1918 to your LAN ranges).
  4. Log denied traffic temporarily while testing.

Step 6 — Test

  • Connect a phone to Company-Guest.
  • Confirm internet works.
  • Try pinging a corporate printer IP — should fail.

Common mistakes

Mistake Symptom
AP uplink access port only Guest SSID clients get no IP
No firewall deny to LAN Guest reaches internal servers
Same VLAN ID on two networks DHCP and routing chaos

For design theory, see WiFi, VLANs, and Network Design Tips.