Skip to content

Custom Templates

Templates in HopBox Cloud let you define reusable device configurations that can be applied to one or many devices at once. They’re essential for managing large deployments where devices share similar network settings.

A template is a predefined configuration that covers one or more aspects of a HopBox device:

  • Network configuration (LAN/WAN/VLAN settings)
  • Firewall rules (zones, traffic rules, port forwards)
  • VPN profiles (WireGuard, OpenVPN, IPsec)
  • SD-WAN policies (routing rules, failover settings)
  • DNS and DHCP settings
  • QoS profiles

When you assign a template to a device or device group, the configuration is pushed automatically on the next sync.

  1. Navigate to Templates in the cloud dashboard
  2. Click New Template
  3. Choose a template type (Network, Firewall, VPN, SD-WAN, or Full Device)
  4. Configure the settings using the visual editor or JSON mode
  5. Save the template with a descriptive name
branch-office-network.json
{
"name": "Branch Office - Standard",
"type": "network",
"config": {
"lan": {
"ipaddr": "192.168.1.1",
"netmask": "255.255.255.0",
"dhcp": {
"enabled": true,
"start": 100,
"limit": 150,
"leasetime": "12h"
}
},
"wan": {
"proto": "dhcp",
"dns": ["1.1.1.1", "8.8.8.8"]
},
"vlans": [
{
"id": 10,
"name": "Staff",
"subnet": "192.168.10.0/24"
},
{
"id": 20,
"name": "Guest",
"subnet": "192.168.20.0/24"
}
]
}
}

Templates support variables for values that differ between devices. Use double curly braces to define placeholders:

{
"lan": {
"ipaddr": "{{lan_gateway}}",
"netmask": "{{lan_netmask}}"
},
"wan": {
"proto": "{{wan_proto}}"
}
}

When assigning the template, you’ll be prompted to fill in the variable values for each device.

  1. Go to Devices → [Your Device] → Settings
  2. Under Templates, click Assign Template
  3. Select the template and fill in any variables
  4. Click Apply — the config will be pushed on next sync
  1. Go to Device Groups → [Your Group]
  2. Click Assign Template
  3. Select the template — it will apply to all devices in the group
  4. New devices added to the group will automatically receive the template

Templates support versioning. Each time you edit and save a template, a new version is created. You can:

  • View version history to see what changed
  • Roll back to a previous version if needed
  • Compare versions side by side

When multiple templates are assigned to a device, they’re applied in priority order:

  1. Device-specific templates (highest priority)
  2. Group templates
  3. Global templates (lowest priority)

Conflicting settings are resolved by priority — higher-priority templates override lower ones.

  • Start with a base template for common settings (DNS, NTP, firewall defaults) and layer specific templates on top
  • Use device groups to organize devices by location, role, or configuration profile
  • Test templates on a single device before rolling out to a group
  • Use variables for site-specific values like IP addresses and VLAN IDs
  • Review sync status after applying templates to confirm successful deployment