1. Before you start: discover your interfaces (read-only)
Run these on the Ubuntu machine to find interface names, MAC addresses, current addresses and routes, and which back end is in use. They only display information. Use the real names they show instead of the examples on this page.
Placeholders like <INTERFACE> must be replaced by you. sudo netplan get prints any stored Wi-Fi passwords to your terminal.
2. Global settings
3. Interfaces
Add each physical interface you want Netplan to manage, then any virtual devices built on them. Bridges and bonds take their members' place: put addresses on the bridge/bond, not on its members.
Configured interfaces
4. Review & export
Checks
These checks are offline and syntactic: they cannot tell whether your gateway exists, whether a cable is plugged in, or whether the switch carries your VLAN.
YAML preview
This configuration contains Wi-Fi passwords. The exported file contains them in plain text. Netplan files must be readable only by root (chmod 600). Clipboard managers and synced clipboards may keep copies; downloads may be synced by your browser or cloud storage.
5. Install, test and roll back safely
Never apply network changes blindly, especially over SSH. Read every command before running it. This page never runs anything. Have console or out-of-band access ready.
- Files merge. Your file is combined with every other Netplan file; later files (by name) override earlier ones. It is not an isolated replacement. Netplan: YAML structure & merging
- cloud-init. On cloud and many server installs, cloud-init writes
50-cloud-init.yamland may regenerate it at boot. Do not blindly disable cloud-init networking; follow your platform's documentation. cloud-init network configuration - NetworkManager. On Ubuntu Desktop, connections created in the GUI may be stored as
90-NM-*.yamland override earlier files. netplan generatechecks syntax and schema and writes back-end files; it does not prove the network works. netplan generatenetplan tryreverts automatically after a timeout, but has limitations with virtual devices (bridges/bonds/VLANs) and the revert should be verified. It is a safety net, not a guarantee. netplan try manual- Back ends. networkd needs systemd-networkd running; NetworkManager needs the network-manager package and service; Wi-Fi with networkd needs wpasupplicant. This page does not install packages or change services.
- Not a router. Netplan configures this machine's interfaces. It does not provide a DHCP server, NAT, IP forwarding or a firewall.
Troubleshooting (read-only)
6. Compatibility & scope
Sources: Netplan YAML reference, Ubuntu Server networking, Ubuntu netplan.io packages, Netplan security.