Try a PLC free — no signup
String OperationsIntermediateIEC 61131-3

CONCAT (String Concatenation)

Joins two or more strings into a single combined string.

The CONCAT function joins two or more strings together into a single string. It is the primary string-building operation in IEC 61131-3, used for constructing display messages, log entries, communication frames, and formatted output. CONCAT appends the second string to the end of the first string and returns the combined result.

Parameters

Inputs

NameTypeDescription
IN1STRINGFirst string
IN2STRINGSecond string to append

Outputs

NameTypeDescription
OUTSTRINGConcatenated result (IN1 + IN2)

Structured Text Example

// Build alarm message
Alarm_Msg := CONCAT('ALARM: ', Alarm_Description);

// Build log entry with multiple parts
Log_Entry := CONCAT(CONCAT(Date_Str, ' - '), Event_Description);

// Build communication frame
Telegram := CONCAT(CONCAT(Header, Data_Payload), Checksum_Str);

Free · no signup to try

Run this block in your browser

Try the instruction on a live rung before you copy it into a project — nothing to install.

Try it in your browser — no signup

Opens plcsimulationsoftware.com — same team

Prefer ready-made code? Ladder Logic Pack — $29 on Gumroad

Platform-Specific Implementation

S

Siemens (TIA Portal)

Use CONCAT instruction in TIA Portal. Max string length is 254 characters.

AB

Allen-Bradley (Studio 5000)

Use CONCAT instruction in Studio 5000. STRING data type max 82 characters default.

C

CODESYS

Use CONCAT() function in ST. String length depends on declaration.

Common Applications

  • Alarm message construction
  • Log entry formatting
  • Communication frame building
  • HMI display text
  • Report generation

Frequently Asked Questions

What is CONCAT (String Concatenation) in PLC programming?

Joins two or more strings into a single combined string. The CONCAT function joins two or more strings together into a single string. It is the primary string-building operation in IEC 61131-3, used for constructing display messages, log entries, communication frames, and formatted output.

What are common applications of CONCAT (String Concatenation)?

CONCAT (String Concatenation) is commonly used for: Alarm message construction, Log entry formatting, Communication frame building, HMI display text, Report generation.

How do I use CONCAT (String Concatenation) in different PLC platforms?

Siemens: Use CONCAT instruction in TIA Portal. Max string length is 254 characters. Allen-Bradley: Use CONCAT instruction in Studio 5000. STRING data type max 82 characters default. CODESYS: Use CONCAT() function in ST. String length depends on declaration.

Free · no signup to try

Wire this block up and run it

Drop the instruction into a rung, press Run and watch it execute in your browser — then adapt it to your vendor tool.

Try it in your browser — no signup

Opens plcsimulationsoftware.com — same team

Prefer ready-made code? Ladder Logic Pack — $29 on Gumroad