What is NetBIOS? How Does It Work? Explained

Virendra KhunteVirendra Khunte
3 min read

NetBIOS (Network Basic Input/Output System) is a legacy networking protocol that revolutionized local network communication in the early days of computing. Despite being outdated, it still plays a role in certain systems today.

In this blog, we’ll cover:

  1. What is NetBIOS?

  2. How NetBIOS Works

  3. Key Features and Uses

  4. NetBios Services and their port number

  5. NetBIOS vs. NetBEUI vs. NBT

  6. Is NetBIOS Still Relevant?

1. What is NetBIOS?

NetBIOS is a network protocol and programming interface developed by IBM in 1983. It makes it possible for local area network (LAN) devices to communicate for purposes such as:

  • File and printer sharing

  • Network gaming (e.g., classic LAN games)

  • Device naming and discovery

Unlike modern protocols, NetBIOS works at the session layer (Layer 5) of the OSI model, helping applications connect with each other.


2. How NetBIOS Works

NetBIOS provides three core services:

A. Name Service

  • Assigns a unique 16-character name (e.g., OFFICE-PC) to each device on the network.

  • Resolves names to IP addresses (similar to DNS but for LAN).

  • Example: Windows’ "Network Neighborhood" uses this to display nearby devices.

B. Session Service

  • Establishes connection-oriented communication between devices.

  • Used for reliable data transfer (e.g., file sharing via SMB).

C. Datagram Service

  • Enables connectionless messaging (e.g., broadcast alerts).

  • Ideal for lightweight tasks like network announcements.


3. NetBIOS Services & Their Port Numbers

NetBIOS operates via three core services, each using specific ports:

ServiceFunctionPort NumberProtocol
Name ServiceResolves device names (e.g., PC-01)UDP 137UDP
Datagram ServiceHandles broadcast messages (connectionless)UDP 138UDP
Session ServiceManages device connections (e.g., file sharing)TCP 139TCP

4. Practical Applications

  • Windows File Sharing: NetBIOS powers legacy SMB (Server Message Block) protocols.

  • Legacy Software: Older apps and games (e.g., Age of Empires) rely on it for LAN multiplayer.

  • Network Troubleshooting: Tools like nbtstat use NetBIOS for diagnostics.


5. NetBIOS vs. NetBEUI vs. NBT

ProtocolDescription
NetBIOSThe core API/protocol for LAN communication.
NetBEUIA non-routable extension of NetBIOS (limited to LAN).
NBTNetBIOS over TCP/IP: Adapts NetBIOS for modern IP networks.

Today, NBT is the standard as it works over the internet, unlike NetBEUI.


6. Is NetBIOS Still Needed?

When It’s Used:

  • Legacy Systems: Windows XP/7 environments or old industrial systems.

  • Mixed Networks: Some Active Directory functions still reference NetBIOS names.

Security Risks:

  • Vulnerabilities: NetBIOS can expose system names (e.g., via nbtstat -a commands).

  • Best Practice: Disable NetBIOS if unused (via Control Panel > Network Settings).


Conclusion

NetBIOS laid the groundwork for modern networking but is now phased out by TCP/IP and DNS. While rarely needed today, understanding it helps troubleshoot legacy systems and appreciate networking’s evolution.

Got questions? Drop them in the comments!

📊 NetBIOS Ports Overview

ServiceProtocolPort Number
Name ServiceUDP137
Datagram ServiceUDP138
Session ServiceTCP139
0
Subscribe to my newsletter

Read articles from Virendra Khunte directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

Virendra Khunte
Virendra Khunte