Skip to content
ZeroServer.tools

MAC Address Generator

Generate random MAC addresses in several formats.

0 addresses
Addresses Generated: 0Format: colonCasing: UPPERCASEType:

About MAC addresses

A MAC (Media Access Control) address is a 48-bit identifier assigned to network interfaces, written as six octets. The two lowest bits of the first octet are flags, not data, which is why six random bytes do not make a usable address:

  • I/G (bit 0) — clear means unicast, one interface. Set means multicast: a group address, which can never be an interface's own address. Half of all random first octets have it set.
  • U/L (bit 1) — set means locally administered, i.e. safe to invent. Clear means the address claims a globally-unique OUI, and those 24-bit prefixes belong to specific manufacturers, so an invented one can collide with real hardware.

Both toggles default to the only combination that is both usable and honest — (octet0 & 0xFE) | 0x02 — which is what a hypervisor, container runtime or test fixture should use. You can turn either off deliberately, and the tool says what you are getting instead. The vendor-prefix presets are the documented ranges VMware, VirtualBox, Hyper-V, QEMU/KVM and Xen use for generated interfaces, for when matching one is the point.

Randomness comes from crypto.getRandomValues, and every address is generated in your browser — nothing is transmitted.

Built and maintained by Meet Shah · Last updated

What this tool is used for

  • Producing addresses to populate a network inventory fixture.
  • Generating input to exercise MAC address parsing across formats.
  • Producing a locally administered address for a test interface.
  • Filling a demo dataset with plausible hardware identifiers.
  • Testing how a UI renders the various separator conventions.

Frequently Asked Questions

What do the two special bits in the first octet mean?
The lowest bit of octet 0 is the unicast/multicast flag — set means multicast, which is not valid as an interface address at all. The next bit is universal/local: set means locally administered, so the address is yours to assign rather than claiming a vendor's registered range.
Why does randomising six bytes not produce a valid address?
Because two of the 48 bits are flags rather than data. Handing six raw random bytes to a formatter gives a 50% chance of a multicast address and a 50% chance of claiming a global OUI — measured over 20,000 addresses, only 25.2% came out both unicast and locally administered.
What is an OUI?
The Organisationally Unique Identifier — the first three octets, registered with the IEEE and assigned to a manufacturer. It is what lets a network tool name the vendor of an unknown device, and it is exactly what a generated address must not fabricate unless the local bit is set.
Which separator format should I use?
Colons for Linux, macOS and most networking tools; hyphens for Windows and IEEE documentation; a dotted triple of four hex digits for Cisco IOS. They are the same 48 bits, and a device that rejects one spelling usually accepts another.
Are MAC addresses actually unique?
By registration, yes; in practice, no. Virtual machines, containers and privacy-preserving randomisation on phones all mint addresses freely, and cheap hardware has shipped duplicates. Treating a MAC as a stable identity is unreliable, and using one for authentication is trivially defeated by spoofing.

Common errors and gotchas

  • Generating a random address without setting the locally administered bit, which may collide with a real vendor's range.
  • Assuming one format, where colon, hyphen and dot-separated forms all appear.
  • Overlooking the multicast bit, which makes an address invalid as a unicast source.
  • Using a generated address on a live network, where a collision breaks connectivity.
  • Treating the vendor prefix as meaningful in a randomly generated address.

Related Generators tools

Private & free — this tool runs entirely in your browser.

CloudwaysManaged cloud hosting on AWS, GCP & DO — from $11/mo.affiliate