IEC 61131-3 (PLC Programming Languages): Practical Guide for Engineers, Auditors, and Project Teams
IEC 61131-3 is the core international standard for programmable logic controller (PLC) programming languages and software organization. For automation engineers, panel builders, SCADA architects, and EPC teams, it is the reference that defines how PLC applications are structured, how languages are expressed, and how software is made portable across vendors. It is not a general machine safety standard, nor a complete lifecycle standard for control systems; rather, it is the programming-language and software-architecture foundation that sits inside a broader compliance stack.
In European projects, IEC 61131-3 is most often used alongside CE-related obligations, the Machinery Directive or Machinery Regulation transition context, EN ISO 12100, IEC 60204-1, EN 61439, IEC 61508, IEC 62061, ISO 13849-1, and increasingly IEC 62443 for cybersecurity. For auditors, it matters because it defines the expected structure and semantics of PLC software, which affects verification, maintainability, change control, and evidence of conformity.
Scope and exclusions
IEC 61131-3 covers the programming languages and software organization for programmable controllers. The standard defines:
- Programming languages such as Ladder Diagram (LD), Function Block Diagram (FBD), Structured Text (ST), Instruction List (IL in older editions), and Sequential Function Chart (SFC).
- Program organization units, including programs, function blocks, and functions.
- Data types, variables, and basic execution concepts.
- Rules for language elements, syntax, and interoperability concepts.
It does not define the complete hardware design of the PLC, electrical panel construction, network architecture, or safety functions in the sense of a full safety standard. It also does not by itself guarantee portability between vendors, because vendor-specific libraries, runtime behavior, scan cycle details, and system function blocks may still differ. In practice, IEC 61131-3 compliance is necessary but not sufficient for a robust industrial control system.
Important exclusion to note: the 3rd edition removed Instruction List from the main language set for new development emphasis, although legacy systems may still encounter it. This is relevant in brownfield migration projects and audits of installed software.
Structure of the document
The standard is organized around the software model of a PLC application. Engineers should think of it as a grammar plus a design framework. The practical structure is typically:
- General principles and definitions.
- Programming model and execution concepts.
- Language definitions for LD, FBD, ST, and SFC.
- Data types, variables, and storage classes.
- Program organization units: functions, function blocks, programs.
- Common elements such as assignments, calls, and expressions.
For implementation work, the most useful parts are the clauses defining how software is decomposed and how each language behaves. For audit work, the clauses around data typing, variable scope, and execution semantics are usually the most referenced because they determine whether the code is deterministic and maintainable.
Most important clauses engineers and auditors actually reference
| Clause / topic | Why it matters in practice | Typical use in engineering or audit |
|---|---|---|
| Programming languages overview | Defines the accepted language set and intended usage | Checks whether the project standard allows LD, FBD, ST, SFC, or legacy IL |
| Data types and variables | Controls type safety, memory use, and interface clarity | Reviews tag naming, BOOL/INT/DINT/REAL usage, and interface contracts |
| Functions, function blocks, programs | Defines modularity and code reuse patterns | Validates software architecture and separation of concerns |
| Sequential Function Chart | Useful for sequence control and state-based logic | Checks recipe, batching, and machine sequence implementation |
| Structured Text semantics | Critical for calculations, algorithms, and advanced logic | Reviews arithmetic, loops, conditional execution, and readability |
| Ladder / Function Block behavior | Common in discrete control and diagnostics | Checks scan-cycle behavior and interlock implementation |
Auditors often focus less on the “language name” and more on whether the software design is disciplined: clear interfaces, predictable execution, and traceable changes. For example, a function block with explicit inputs and outputs is easier to verify than a dispersed network of global variables.
Verification and conformity-assessment methods
IEC 61131-3 itself is not a certification scheme, so conformity is usually demonstrated through engineering evidence rather than a single test certificate. Common verification methods include:
- Static review: inspect program structure, naming conventions, variable scopes, and use of language features.
- Traceability review: link requirements to code modules, test cases, and acceptance criteria.
- Simulation and offline testing: execute code in a vendor simulator or virtual controller before site deployment.
- Unit and integration testing: verify functions, function blocks, and sequence logic in isolation and in system context.
- Peer review / independent check: particularly important for safety-related or high-availability logic.
- Change impact analysis: confirm that modifications preserve intended behavior and do not break dependencies.
For safety-related applications, IEC 61131-3 should be used together with the safety lifecycle and verification expectations of IEC 61508, IEC 62061, or ISO 13849-1. If software is part of a machine control system, the documentation should also align with IEC 60204-1 and the risk reduction strategy from EN ISO 12100. For cybersecurity-relevant control systems, IEC 62443 practices are increasingly expected, especially where remote access, engineering workstations, or networked PLCs are involved.
A practical conformity mindset is: if a function block is intended to be reusable, it should be tested as a reusable asset. If a sequence is intended to be deterministic, the scan-cycle and state transitions should be documented and validated. If a variable is safety-significant, it should be protected by design and not treated like ordinary process data.
Common pitfalls during certification and project acceptance
- Overusing global variables: this reduces traceability and makes audits harder.
- Mixing vendor-specific features into core logic: portability drops and future migration becomes expensive.
- Ignoring execution order: in cyclic PLCs, scan order can change outcomes, especially with shared variables.
- Using ST without coding discipline: unreadable nested logic and implicit conversions create defects.
- Treating SFC as a complete safety mechanism: sequence control is not the same as safety function design.
- Neglecting version control and change records: auditors want evidence of controlled software release.
- Assuming IEC 61131-3 equals CE compliance: it does not; it is only one element of the technical file.
One frequent issue in panel and machine projects is that the PLC software is developed in isolation from the wiring and I/O schedules. That leads to mismatches between tag names, terminal plans, and actual field devices. A disciplined naming convention and signal list review can prevent costly commissioning delays.
Relationship to adjacent standards
IEC 61131-3 is best understood as part of a standards ecosystem:
- IEC 61131-2: equipment requirements and tests for PLC hardware.
- IEC 60204-1: electrical equipment of machines; important for control circuits, emergency stops, and documentation.
- EN ISO 12100: risk assessment and risk reduction for machinery.
- ISO 13849-1 and IEC 62061: safety-related control system design and validation.
- IEC 61508: functional safety foundation, especially for process and high-integrity systems.
- IEC 61439: low-voltage switchgear and controlgear assemblies; critical for panel builders.
- IEC 62443: industrial automation and control system cybersecurity.
- ISA-88 and ISA-95: batch and enterprise integration models that influence PLC/SCADA structuring.
- NFPA 79: useful in North American machine control contexts, especially for cross-border projects.
For SCADA architects, IEC 61131-3 influences how PLC data is exposed upward: clean function block interfaces, stable tag models, and predictable states make historian mapping, alarm handling, and HMI design far easier. For contractors, it affects FAT/SAT scope because software structure determines how much can be verified before site energization.
How it shapes design decisions in automation, panel, SCADA, and contracting work
In real projects, IEC 61131-3 drives design choices in five practical ways:
- Modularity: use function blocks for repeated equipment such as pumps, valves, drives, and conveyors.
- Readability: choose LD or FBD for simple interlocks and ST for calculations, data handling, and advanced sequences.
- Determinism: design with scan-cycle behavior in mind; avoid hidden dependencies.
- Interface discipline: define clear input/output contracts for all reusable blocks.
- Lifecycle control: version, test, approve, and archive code like any other engineered deliverable.
For panel builders, this means wiring and I/O schedules should align with software module boundaries. For SCADA teams, it means alarm, event, and status tags should be derived from well-structured PLC objects rather than ad hoc variables. For EPC and contracting teams, it means software deliverables should be specified in the scope: language mix, naming rules, library policy, simulation expectations, and acceptance criteria.
A simple engineering rule is that the more reusable and safety-significant the software, the more structure it needs. If a control function is expected to be maintained for 15 years across multiple sites, IEC 61131-3 discipline is not optional; it is the foundation for maintainability, auditability, and vendor independence.
Clause-by-purpose summary
| Purpose | What to look for in IEC 61131-3 | Project implication |
|---|---|---|
| Language selection | LD, FBD, ST, SFC definitions | Set a project coding standard |
| Software architecture | Functions, function blocks, programs | Define reusable modules and interfaces |
| Data integrity | Types, variables, scope rules | Reduce ambiguity and integration errors |
| Sequence control | SFC and state logic concepts | Improve batch, machine, and startup/shutdown logic |
| Verification | Deterministic logic and structured code | Enable testing, simulation, and review |
| Audit readiness | Clear structure and traceability | Support technical file and FAT/SAT evidence |
For most industrial teams, the best way to use IEC 61131-3 is not to treat it as a compliance checkbox, but as the coding and architecture language of disciplined automation. When combined with the right electrical, safety, and cybersecurity standards, it becomes a practical tool for building systems that are easier to commission, safer to operate, and simpler to maintain.
Services that must comply
Industries where this applies
- Manufacturing & Process Industry
Discrete and process manufacturing plants — assembly, packaging, machining, batching — where PLC/SCADA, drives, and standardized panels run production lines and OEE drives investment decisions.
Read → - Food & Beverage
Hygienic-design automation and panels for dairies, breweries, beverage lines, and food processing — IP65/IP69K enclosures, washdown-rated control cabinets, traceability, and FSMA/EU 178/2002 compliance.
Read → - Automotive & EV Manufacturing
OEM and tier-1 supplier plants — body shop, paint, assembly, EV battery — robot integration, PLC line control, NFPA 79 / EN 60204-1 panels, and MES-tier traceability.
Read → - Water & Wastewater
Municipal and industrial water plants — pumping stations, treatment processes, lift stations — RTU-based SCADA with cellular telemetry and remote monitoring across geographically distributed assets.
Read → - Oil & Gas
Upstream, midstream, and downstream — wellhead automation, terminal SCADA, ATEX/IECEx Ex-rated panels, IEC 61511 safety-instrumented systems, and corrosion-resistant enclosures for harsh service.
Read →
Frequently asked questions
What programming languages are defined by IEC 61131-3 for PLCs, and when should each be used in industrial projects?
IEC 61131-3 defines five PLC programming languages: Ladder Diagram (LD), Function Block Diagram (FBD), Structured Text (ST), Instruction List (IL, now deprecated in the third edition), and Sequential Function Chart (SFC). In practice, LD is common for discrete logic and maintenance-friendly troubleshooting, ST is preferred for complex calculations and data handling, FBD suits process control and signal flow, and SFC is used for step-based sequences. The standard is part of the IEC 61131 series and is widely referenced in European automation projects for consistent PLC application design.
How does IEC 61131-3 help standardize PLC programming across different OEMs and system integrators?
IEC 61131-3 provides a common syntax and execution model that improves portability of control logic between PLC platforms, reducing vendor lock-in and easing multi-site standardization. It also defines program organization units such as functions, function blocks, and programs, which helps EPC contractors and OEMs build reusable libraries and common coding standards. For European projects, this aligns well with structured engineering practices and supports maintainability across the asset lifecycle.
Is IEC 61131-3 compliance enough for a PLC program to be considered safe in a machine or process application?
No, IEC 61131-3 only defines the programming languages and software structure for PLCs; it does not by itself establish functional safety. Safety-related control functions must be designed and validated against standards such as IEC 61508 and, for machinery, IEC 62061 or ISO 13849-1, depending on the application. In panel and SCADA projects, the safety architecture, diagnostics, and proof testing must be addressed separately from the PLC coding standard.
What is the practical difference between Structured Text and Function Block Diagram for SCADA-integrated control systems?
Structured Text is better for arithmetic, data manipulation, communication handling, and algorithmic tasks such as batching or recipe management, while Function Block Diagram is often easier for engineers to visualize in analog loops and interlocks. In SCADA-integrated projects, ST is frequently used for backend logic and data processing, whereas FBD is used for control loops that need clear engineering visibility during commissioning. Both are IEC 61131-3 languages, and many platforms allow mixed-language projects within the same application.
How should PLC code be structured under IEC 61131-3 for large industrial plants with multiple panels and remote I/O stations?
A good IEC 61131-3 structure separates hardware abstraction, equipment modules, and process sequences into reusable function blocks and programs, making the code easier to test and maintain. This is especially important in plants with distributed I/O, multiple MCC or control panels, and SCADA communication layers, because it reduces coupling between equipment and site-level logic. Using naming conventions, version control, and modular libraries also supports FAT, SAT, and long-term lifecycle support on EPC projects.
Does IEC 61131-3 specify how PLC tags, variables, and data types should be managed in engineering projects?
Yes, IEC 61131-3 defines data types, variable declarations, scope rules, and basic programming constructs that govern how tags and variables are used in PLC applications. This helps engineers create deterministic, readable code with clear separation between local, global, and retained variables, which is critical for diagnostics and change control. For European compliance-focused projects, disciplined tag architecture also improves traceability during commissioning and maintenance.
What are the implications of IEC 61131-3 for PLC certification or vendor selection on international projects?
IEC 61131-3 is a programming standard, not a formal product certification mark, so a PLC is not “certified to IEC 61131-3” in the same way a device might be certified for EMC or safety. However, PLC platforms that support the standard’s languages and execution model make it easier to transfer code between projects and vendors, which is a major advantage for global EPC work. When selecting vendors, engineers should also check conformity with related standards such as IEC 60204-1 for machinery electrical equipment and IEC 61131-2 for PLC equipment requirements.
Why was Instruction List removed from newer IEC 61131-3 editions, and what should engineers use instead?
Instruction List was deprecated and removed in the third edition because it was less readable, harder to maintain, and less suitable for modern software engineering practices. Engineers should migrate legacy IL logic to Structured Text, Ladder Diagram, or Function Block Diagram depending on the control function and maintainability requirements. On retrofit and brownfield projects, the migration strategy should include functional verification, regression testing, and documentation updates to preserve operational integrity.
