update page now

New: EU CAPTCHA – GDPR-compliant bot protection. Try it free for 3 months!

Messages on a cell phone

OSI Model Explained: Structure, Layers, and Importance

The OSI model (Open Systems Interconnection) is a reference model that divides network communication into seven clearly defined layers. Each layer performs a specific task — from physical signal transmission to the application level. The model ensures that devices from different vendors can communicate with each other reliably and without errors.

Learn more about how to protect Layer 7 with a WAF

01

What is the OSI model?

The OSI model (also known as the OSI layer model or ISO/OSI model) is a conceptual framework for network communication.

  • OSI stands for Open Systems Interconnection

  • ISO stands for International Organization for Standardization

  • The model describes how data is exchanged between two systems across a network

  • It divides communication into 7 layers

  • Each layer has a clearly defined task

The OSI model is based on the concept of splitting a communication system into seven abstract layers that build on one another. Each layer performs a specific role and communicates with the layers above and below it.

02

Why was the OSI model developed?

Before the OSI model was introduced, there was no unified standard for network communication. In the early 1980s, many incompatible machine technologies and operating systems existed from companies such as IBM, Burroughs, Univac, and Hewlett Packard — with no agreed-upon standards for how two different computer systems could exchange data.

 

The main goals of the OSI model:

  • Standardization of network communication

  • Vendor independence between devices

  • Troubleshooting through clear separation of layers

  • Modular development of individual network components

  • Interoperability across different systems

 

In May 1983, documents from CCITT and ISO were merged into the "Basic Reference Model for Open Systems Interconnection" and published in 1984 as ISO standard 7498.

03


How is the OSI model structured?

The OSI model consists of seven layers that build on each other. On the sender's side, data moves from Layer 7 down to Layer 1, is transmitted, and is then reassembled in reverse order on the receiver's side.

Mnemonic: "Please DNot Throw Salami Pizza Away" – the initial letters stand for Physical, Data Link, Network, Transport, Session, Presentation, Application.

  • 7

    Application Layer

    6

    Presentation Layer

    5

    Session Layer

    4

    Transport Layer

    3

    Network Layer

    2

    Data Link Layer

    1

    Physical Layer

    7

    Interface to applications

    6

    Data formatting, encryption

    5

    Connection setup and control

    4

    Segmentation, transmission control

    3

    Routing, logical addressing

    2

    Node-to-node transmission

    1

    Physical signal transmission

    Layer
    Name
    Task

    7

    Application Layer

    Interface to applications

    6

    Presentation Layer

    Data formatting, encryption

    5

    Session Layer

    Connection setup and control

    4

    Transport Layer

    Segmentation, transmission control

    3

    Network Layer

    Routing, logical addressing

    2

    Data Link Layer

    Node-to-node transmission

    1

    Physical Layer

    Physical signal transmission

    04

    What are the tasks of the 7 OSI layers?

    Layer 7 – Application Layer

    This is the only layer that interacts directly with user data. Software applications such as web browsers and email clients rely on the Application Layer to initiate communication. The Application Layer is responsible for the protocols and data processing on which the software depends.

    • Interface to the application (not the application itself)

    • Protocols: HTTP, HTTPS, FTP, SMTP, DNS

    • Attack surface for Layer 7 attacks (e.g., DDoS attacks on web applications)

    Layer 6 – Presentation Layer

    The Presentation Layer translates data into a uniform format.

    • Encryption and decryption (e.g., TLS/SSL)

    • Data compression

    • Character set conversion (e.g., ASCII, Unicode)

    • Data formatting

    Layer 5 – Session Layer

    Layer 5 establishes, coordinates, and terminates sessions between systems in a network. The Session Layer is responsible for identifying, establishing, maintaining, and closing communication sessions between applications on network nodes.

    • Session management

    • Synchronization of data exchange

    • Resumption of interrupted connections

    Layer 4 – Transport Layer

    The Transport Layer ensures reliable data transmission between end systems.

    • Segmentation of large amounts of data

    • Error correction and flow control

    • Connection-oriented (TCP) or connectionless (UDP)

    • End-to-end communication

    Layer 3 – Network Layer

    The Network Layer handles routing between networks.

    • Logical addressing via IP addresses

    • Path finding (routing) between different networks

    • Packet forwarding

    • Examples: IP, ICMP, routers

    Layer 2 – Data Link Layer

    The Data Link Layer ensures node-to-node data transmission between two directly connected nodes. It detects and, where possible, corrects errors that may occur at the physical layer. It also defines the protocol for establishing and terminating a connection between two physically connected devices, as well as the protocol for flow control.

    • Works with MAC addresses

    • Examples: Ethernet, switches, Wi-Fi (IEEE 802.11)

    Layer 1 – Physical Layer

    The lowest layer handles the physical transmission of data.

    • Responsible for sending and receiving unstructured raw data between a device and a physical transmission medium. It converts digital bits into electrical, radio, or optical signals.

    • Defines voltage levels, cables, connectors, and timing

    • Examples: Ethernet cables, fiber optics, Wi-Fi radio signals

    05

    How does data transmission work in the OSI model?

    When sending an email, the message passes through all seven layers: For human-readable information to be transmitted across a network from one device to another, the data must travel down through the seven layers on the sending side and back up on the receiving side. The email application hands the message to the Application Layer, which selects a protocol (SMTP) and passes the data to the Presentation Layer. The Presentation Layer compresses the data and forwards it to the Session Layer, which initializes the communication session. The data then moves to the Transport Layer, where it is segmented, then to the Network Layer, where it is broken into packets, and finally to the Data Link Layer, where it is converted into frames.

     

    This process is called data encapsulation. On the receiver's side, the process runs in reverse (de-encapsulation).

    06


    How does the OSI model differ from the TCP/IP model?

    The TCP/IP model is the dominant model used in today's internet. However, the OSI model remains the most important didactic and analytical reference framework. The biggest difference between the two models is that the OSI model separates several functions that the TCP/IP model groups into single layers. This affects both the application layer and the network access layer of the TCP/IP model.

    The modern internet is not built on OSI but on the simpler TCP/IP model. Nevertheless, the OSI 7-layer model is still widely used because it helps visualize and communicate how networks function.

  • Number of layers

    7

    Type

    Reference model

    Focus

    Protocol-independent

    Usage

    Teaching, troubleshooting

    Flexibility

    High

    Number of layers

    4-5

    Type

    Practical model

    Focus

    Protocol-specific

    Usage

    Real-world internet

    Flexibility

    Medium

    Criterion
    OSI Model
    TCP/IP Model

    Number of layers

    7

    4-5

    Type

    Reference model

    Practical model

    Focus

    Protocol-independent

    Protocol-specific

    Usage

    Teaching, troubleshooting

    Real-world internet

    Flexibility

    High

    Medium

    Code on a screen

    07

    Why is the OSI model still relevant today?

    Although the internet is technically based on TCP/IP, the OSI model remains indispensable:

    • Troubleshooting: Whether a single person can't connect their laptop to the internet or a website is unreachable for thousands of users, the OSI model helps narrow down the problem and isolate the source. If the issue can be pinpointed to a specific layer, a lot of unnecessary work can be avoided.

    • Network design: structured planning of complex architectures

    • IT security: targeted protective measures per layer (e.g., WAF on Layer 7, Network DDoS Protection on Layer 3/4)

    • Education: universal learning foundation for IT professionals

    • Communication: a shared language between developers, admins, and vendors

    08


    What security risks exist at each OSI layer?

    Every layer of the OSI model offers its own attack surface. Layer 7 attacks are particularly critical today because they target complex web applications and often bypass traditional firewalls.

  • Layer 7 (Application)

    DDoS, SQL injection, XSS

    Layer 6 (Presentation)

    SSL stripping, weak encryption

    Layer 5 (Session)

    Session hijacking

    Layer 4 (Transport)

    SYN flood, TCP reset

    Layer 3 (Network)

    IP spoofing, ICMP flood

    Layer 2 (Data Link)

    ARP spoofing, MAC flooding

    Layer 1 (Physical)

    Cable tampering, eavesdropping

    Layer 7 (Application)

    DDoS Protection, WAF, Bot Management

    Layer 6 (Presentation)

    TLS, strong certificates, Post-quantum cryptography

    Layer 5 (Session)

    Session tokens, timeouts

    Layer 4 (Transport)

    DDoS Network Protection

    Layer 3 (Network)

    DDoS Network Protection

    Layer 2 (Data Link)

    Port security, VLANs

    Layer 1 (Physical)

    Physical access controls

    Layer
    Typical attacks
    Countermeasures

    Layer 7 (Application)

    DDoS, SQL injection, XSS

    DDoS Protection, WAF, Bot Management

    Layer 6 (Presentation)

    SSL stripping, weak encryption

    TLS, strong certificates, Post-quantum cryptography

    Layer 5 (Session)

    Session hijacking

    Session tokens, timeouts

    Layer 4 (Transport)

    SYN flood, TCP reset

    DDoS Network Protection

    Layer 3 (Network)

    IP spoofing, ICMP flood

    DDoS Network Protection

    Layer 2 (Data Link)

    ARP spoofing, MAC flooding

    Port security, VLANs

    Layer 1 (Physical)

    Cable tampering, eavesdropping

    Physical access controls

    Laptop, tablet and cell phone lie side by side on a table

    09

    Conclusion: A reference model for network communication

    The OSI model, often referred to as the ISO/OSI layer model, is a reference model used to describe and define communication between systems. It consists of seven distinct layers, each with clearly defined responsibilities. Learn here how Myra Security protects the most critical layers from malicious traffic and attacks with its solutions.

    Learn more about the Myra Security-as-a-Service Platform

    FAQ – Frequently Asked Questions about the OSI Model

    The OSI model is a reference framework that divides network communication into seven layers. Each layer has a clear task — from the cable to the application.

    About the author

    Stefan Bordel

    Senior Editor

    About the author

    Stefan Bordel has been working as Editor and Technical Writer at Myra Security since 2020. He is responsible for the strategic development and editorial management of all content formats – from website content and specialist publications to whitepapers, social media communication, and technical documentation. In this role, he combines solid expertise from IT journalism with in-depth technical understanding in the field of cybersecurity. As a long-time Linux enthusiast, he closely follows developments in the IT industry both professionally and personally.