Unit 7 · Prepare your data

How to recode and reverse-score items in SPSS

Reverse-score questionnaire items and group values with Recode into Different Variables in SPSS, step by step.

Free tutorialPro practiceAbout 5 minutes7 practice questions

Quick answer: How do you recode and reverse-score items in SPSS?

  1. Click Transform › Recode into Different Variables.
  2. Move the item across, type a new name (such as anx3_r) and click Change.
  3. Click Old and New Values and add each pair (1 → 5, 2 → 4, 3 → 3, 4 → 2, 5 → 1).
  4. Click Continue, then OK.

Last updated November 2026 · Not sure this is the right test? Try the Which statistical test? tool.

Recoding and reverse-scoring

Recoding changes the values of a variable according to rules you set, such as reversing a negatively worded questionnaire item or grouping ages into bands. Reverse-scoring makes sure a high number means the same thing on every item before you add them up.

When to use it

  • Questionnaires with reverse-worded items (“I rarely feel anxious” in an anxiety scale).
  • Collapsing categories, such as combining small groups.
  • Turning a Scale variable into bands, though this throws information away.

How it works

For a scale running from a minimum to a maximum, reversed score = (minimum + maximum) − score. On a 1–5 scale, 1 becomes 5 and 2 becomes 4. Recode into Different Variables creates a new variable and keeps the original, so mistakes are easy to fix.

Worked example

On a four-item anxiety scale, item 3 is “I feel calm”. After recoding into anx3_r, a 5 (strongly agree) becomes a 1, matching the meaning of the other items.

Key terms

Reverse-worded item
An item where agreeing means less of the trait.
Recode into Different Variables
Creates a new variable, keeping the original.

Common mistakes

  • Recoding into the same variable and losing the original data.
  • Forgetting a value (such as the midpoint), which then becomes missing.
  • Reversing the same item twice.

How to do it in SPSS

Recode into Different Variables

Questionnaires often include reverse-worded items, such as “I rarely feel anxious” in an anxiety scale. Before adding up a scale, flip those items so a high score always means the same thing.

Recode into Different Variables
Variables
Anxiety item 1 [anx1]
Anxiety item 2 [anx2]
Anxiety item 4 [anx4]
Numeric Variable -> Output Variable:1
anx3 --> anx3_r
Output Variable2
Name: anx3_r
Label: Anxiety item 3 (reversed)
Change
Old and New Values…3If… (optional case selection condition)
OKPaste4ResetCancelHelp
  1. 1
    The variable to recodeMove the reverse-worded item here. SPSS shows old name --> new name once you’ve clicked Change.
  2. 2
    Output VariableType a new name (anx3_r is a common convention) and a label, then click Change. The original anx3 stays untouched.
  3. 3
    Old and New Values…Opens the box where you say which old code becomes which new code.
  4. 4
    PasteClick Paste instead of OK to keep a record of the recode in syntax. You’ll thank yourself when writing your method.

Use Recode into Different Variables, not Same Variables. If you make a mistake, the original data are still there.

Old and New Values

For a 1–5 item, reversing means 1 becomes 5, 2 becomes 4, 3 stays 3, and so on.

Recode into Different Variables: Old and New Values
Old Value1
✓Value: 1
System-missing
System- or user-missing
Range, LOWEST through value
All other values
New Value2
✓Value: 5
System-missing
Copy old value(s)
Old --> New:3
1 --> 5
2 --> 4
3 --> 3
4 --> 2
5 --> 1
Add4ChangeRemove
ContinueCancelHelp
  1. 1
    Old ValueThe code as it is now. Range options let you group values, such as ages 18 through 24.
  2. 2
    New ValueWhat that code should become.
  3. 3
    Old --> New listEvery rule you’ve added. Check it covers every possible answer, including 3.
  4. 4
    AddClick Add after each pair. Forgetting it is the most common reason a recode “doesn’t work”.

Quick formula: reversed score = (lowest + highest) − score. For a 1–7 scale that’s 8 − score.

The SPSS syntax

Prefer typing to clicking? Open File › New › Syntax, paste this in, select it and choose Run › Selection. Every dialog's Paste button writes the same kind of code.

RECODE anx3 (1=5) (2=4) (3=3) (4=2) (5=1) INTO anx3_r.
VARIABLE LABELS anx3_r 'Anxiety item 3 (reversed)'.
EXECUTE.

Practice data

Download the file used in this lesson and run it yourself in SPSS: you should get the same results as the screens above.

  • anxiety_items.savFour anxiety items, one reverse-worded, with some missing answers (N = 100)

Now practise it interactively →

Reading is only half of it. Tap through the real SPSS menus, read the output and pick the right write-up in 7 quick questions, with instant feedback on every answer.

Practice for this lesson is part of Pro, with every unit, unlimited hearts and saved progress.

More in Prepare your data