← Text & List Tools
Text & List Tools · runs locally

Rail Fence Cipher Tool

Encode or reconstruct text with a bounded zigzag rail transposition while keeping every input character intact.

Ready. Your working data stays in this browser.

Why this tool is useful

Use Rail Fence for visual transposition exercises where character order changes but the original alphabet and punctuation do not.

How it works

Encoding walks down and up across 2–50 rails before reading rows; decoding rebuilds the same zigzag positions and fills them from the ciphertext.

Practical example

Three rails turn WEAREDISCOVEREDFLEEATONCE into WECRLTEERDSOEEFEAOCAIVDEN and the inverse path restores the plaintext.

Validation

The calculation is deterministic and explains validation errors instead of silently changing invalid input.

Privacy boundary

Input and output remain in this tab. Copy and download happen through browser APIs without a server upload.

Result passport

Every run reports its tool mode, timestamp and input/output size so transformed data can be audited.