Letter Decrementer

Shifts every letter in your text backward by a chosen number of positions in the alphabet, wrapping a back to z and A back to Z, the inverse of an adjustable Caesar-cipher shift that preserves case and leaves non-letters untouched. A free online tool from Staaarter, right in your browser.

Runs locallyUpdated 2026-07-23

Overview

Introduction

Reversing a Caesar-style letter shift requires shifting every letter backward by the same amount it was originally shifted forward.

This tool does that directly, and runs entirely client-side, so nothing you paste is ever uploaded to a server.

What Is Letter Decrementer?

A generalized reverse Caesar-shift tool that moves every letter backward by a chosen number of alphabet positions, wrapping from a back to z (and A back to Z) when it runs past the start.

It's part of this site's String Tools collection and works entirely in your browser.

How Letter Decrementer Works

For every letter, the tool finds its position in the alphabet (0-25), subtracts the shift amount, wraps the result with a modulo-26 operation, and converts it back to a character, preserving the original uppercase or lowercase.

Non-letter characters, including digits, spaces, and punctuation, pass through completely unchanged.

When To Use Letter Decrementer

Use it to reverse text that was shifted forward with Letter Incrementer, by entering the same shift amount.

It's also useful on its own for puzzle-making or teaching Caesar-cipher shifts in the backward direction.

Often used alongside Letter Incrementer and ROT13 Encoder/Decoder.

Features

Advantages

  • Adjustable shift amount, unlike a fixed ROT13.
  • Exact inverse of Letter Incrementer when the same shift amount is used.
  • Guards against a negative modulo result, so the wrap from 'a' back round to 'z' is correct instead of producing an out-of-range character.

Limitations

  • Not real encryption or security; Caesar shifts are trivially breakable and only 26 possible shifts exist.
  • Only supports the basic Latin alphabet; accented or non-Latin letters are left unchanged.

Examples

Shifting backward by 3

Input

def ABC

Output

abc XYZ

Each letter moves 3 positions backward; A, B, C wrap around back to X, Y, Z.

Best Practices & Notes

Best Practices

  • Use the same shift amount that was used to encode the text, for a clean round trip.
  • Remember a shift of 13 in either direction produces the same result, since 13 is its own inverse modulo 26.
  • Treat this as a puzzle or teaching aid rather than a security measure, since a 26-position alphabet shift offers no real protection.

Developer Notes

The core formula is `((charCode - base - shift) % 26 + 26) % 26 + base`, where `base` is 65 for uppercase or 97 for lowercase. The extra `+ 26) % 26` guards against negative shift values producing a negative modulo result.

Letter Decrementer Use Cases

  • Reversing text shifted with Letter Incrementer
  • Teaching or demonstrating reverse Caesar-cipher shifts
  • Puzzle-making that requires a backward alphabet shift

Common Mistakes

  • Using the wrong shift amount, which produces gibberish instead of the original text.
  • Treating this as secure decryption; Caesar shifts offer no real security since there are only 26 possible shifts to try.

Tips

  • If you don't know the original shift amount, try Letter Incrementer or Letter Decrementer with each value from 1 to 25 until the text reads correctly.
  • Only A-Z and a-z are shifted, so accented letters, digits, and punctuation pass through untouched and can leak the structure of the original text.

References

Frequently Asked Questions