PLC · 7 min read · Updated July 2026
IEC 61131-3 Languages: Ladder, ST, FBD — Which to Use When
All five PLC languages compile to the same scan — but maintainability differs enormously. A field-tested guide to choosing the language per routine, based on who maintains it and what it does.
Most plants standardize on the language the first integrator happened to use. A better approach: pick the language per routine, based on who maintains it and what it does. All IEC 61131-3 languages are available in TIA Portal, GX Works3, Sysmac Studio, Studio 5000 and CODESYS — the choice is yours, not the vendor's.
Ladder Diagram (LD): the maintenance language
Electricians and technicians read ladder fluently because it mirrors relay schematics. Use it for interlocks, motor starters, valve sequencing and anything a technician must troubleshoot online at 3 a.m. Online monitoring shows power flow rung by rung, which is the fastest way to find a stuck permissive. Its weakness: math, loops and string handling become unreadable chains of MOVE and CALCULATE boxes.
Structured Text (ST): the engineering language
ST is Pascal-like code — the right tool for calculations, recipe handling, data structures, communication parsing and any algorithm with branching and loops. Modern platforms make ST a first-class citizen with code completion and debugging. Rule of thumb: if a ladder rung needs more than two math boxes, it wants to be ST inside a function block with a clear name and commented inputs.
Function Block Diagram (FBD): signal flow
FBD shines where the logic is a chain of processing blocks — scaling, filtering, PID, selection logic in process applications. Process engineers often read FBD better than ladder, and continuous control in water and chemical plants is naturally expressed as blocks connected by signals.
The other two
- Sequential Function Chart (SFC) — the right tool for machine phases and batch steps. State machines hand-coded in ladder with dozens of latch bits are the most common source of "stuck sequence" calls we receive. SFC (GRAPH in TIA Portal) makes the sequence visible and restartable.
- Instruction List (IL) — deprecated in the standard since 2013. Migrate away when touching old code.
Practical standardization rules
- Interlocks and safety-adjacent logic: ladder, always visible online.
- Sequences and phases: SFC, or a documented state-machine pattern in ST with an enumerated state variable.
- Math, data, communication: ST in well-named function blocks with typed interfaces.
- One language per program organization unit. Mixed logic inside one block is where bugs hide.
- Write for the reader. The next person to open the project is a technician, not the original programmer — name variables in the plant's language, comment the intent, not the syntax.
Platform notes
- Siemens TIA Portal: LAD, FBD, SCL (ST) and GRAPH (SFC) on S7-1200 and S7-1500. SCL compiles efficiently on the S7-1200 CPU 1214C — there is no performance reason to avoid it.
- Mitsubishi GX Works3: structured ladder, ST and FBD/LD; function blocks shared across iQ-F and iQ-R.
- Omron Sysmac Studio: ladder and ST with inline ST inside ladder rungs on the NX1P2; PLCopen motion blocks are ST-friendly.
- CODESYS (WAGO, ABB, many others): all five languages plus CFC; the WAGO PFC200 runs the same code as any other CODESYS V3 target.
We refactor and standardize PLC code bases as part of our engineering services — ask about a code review of your critical machines before the next shutdown.
Need engineering help with this?
Our engineers apply this to real projects every week — selection, specification, commissioning. Send your question or a part number.
Quick answers
Is Structured Text harder for technicians to troubleshoot?
Online monitoring of ST shows variable values but not the signal flow a ladder rung shows. That is why we keep interlocks and anything a night-shift technician must trace in ladder, and use ST for calculations and data handling behind well-named function blocks.