Get notified
In this guideThe short versionWhat is a codebook, and do you need one?What goes in each entryHow to build oneStructure: parents, children and levelsWorking with other codersVersion your codebookCommon mistakesA small worked codebookInductive and deductive codebooksMerging, splitting and retiring codesAgreement between codersCodebook checklistFrequently asked questions

← All guides

Analyze

How to build a codebook for qualitative research

What a qualitative codebook contains, a template you can copy, and a step-by-step way to build, test and version one, alone or in a team.

Tralyx guides6 min readReviewed 15 Nov 2026Includes a template

Part of the series: Qualitative data analysis: a step-by-step guide

The short version

  • A codebook is a list of your codes, each with a clear definition, rules for when to use it and an example.
  • It keeps coding consistent over time and between people.
  • Start small, test it on a few transcripts, revise it and record every change.

What is a codebook, and do you need one?

A codebook is the working record of your codes. It tells anyone, including future you, what each code means and when to apply it. Without one, codes drift. A label you used for one idea in week one quietly changes in week six.

Not every approach uses a fixed codebook. Braun and Clarke separate reflexive thematic analysis, where codes grow and change and a fixed codebook isn't expected, from approaches that use a structured codebook, often with more than one coder. Choose the style that matches your method. If you work in a team or need coding to be consistent, a codebook helps a great deal.

What goes in each entry

MacQueen and colleagues (1998)1 describe a structured codebook entry for team-based work. This version adapts their parts for interview studies.

FieldWhat to writeExample (invented)
Code nameA short, specific labelUnable to answer a participant
Short definitionOne lineA researcher could not say where a recording went when asked.
Full definitionA few sentences on what it capturesThe participant describes a moment when someone asked about the handling of their data and the researcher had no clear answer.
When to useWhat countsUse when the participant describes a specific moment, even if the outcome was minor.
When not to useWhat doesn't count, and where it goes insteadNot for general worries about storage. Use "Concern about storage" instead.
ExampleA typical quote"I realized I'd promised her something I couldn't verify."
Near missA quote that looks similar but doesn't fit"I always wonder where files go." (a worry, not a moment)

How to build one

  1. Start from your research questions and from reading a few transcripts. Note topics that recur.
  2. Draft a first list of codes. Mix codes from your theory or earlier work with codes from the data, if your approach allows it.
  3. Write a short definition for each. If you can't define it, it isn't ready.
  4. Test it. Code two or three transcripts with the draft. If a second person is coding, each of you codes the same transcripts alone.
  5. Compare. Where you disagree, talk about the definition. Fix the code's wording, not the person.
  6. Revise the codebook and recode the test transcripts.
  7. Save a dated version. From now on, change it only on purpose, and write down each change.

Structure: parents, children and levels

Group related codes under a broader heading. A parent code such as "Responsibility to participants" might hold child codes like "Unable to answer a participant" and "Telling participants up front." Two or three levels are usually enough. Deeper trees get hard to use.

Keep the total list a size you can hold in your head. If you can't remember the codes, you can't apply them consistently. Merge codes that overlap and retire ones you never use.

Working with other coders

  • Agree on the unit you code, such as a sentence, a paragraph or a topic shift.
  • Agree whether a passage can carry more than one code.
  • Code a shared sample separately, then compare and discuss.
  • Decide who may change the codebook and how changes get approved.
  • If your method uses a reliability statistic, record it, and explain what you did when coders disagreed.

Version your codebook

A simple change log keeps your analysis honest and easy to explain.

VersionDateChangeReason
1.02 MarchFirst draft, 14 codesBased on three transcripts
1.19 MarchMerged two storage codesThey were applied interchangeably
1.216 MarchAdded "Near miss" examplesTwo coders disagreed on borderline cases

The log above is invented, to show the format.

Common mistakes

MistakeFix
Definitions too vague to applyAdd "when to use" and "when not to use"
Too many codesMerge overlaps and drop unused codes
Changing codes silentlyDate every version and log changes
Treating the codebook as finished after one draftTest, revise and recode early transcripts
Writing it only for yourselfWrite so a stranger could use it

A small worked codebook

Here is a tiny invented codebook for a study on how researchers handle recordings. It shows parent and child codes with short definitions.

Parent codeCodeShort definition
Responsibility to participantsUnable to answer a participantCould not say where a recording went when asked.
Responsibility to participantsTelling participants up frontExplains handling of recordings before the interview.
Storage choicesConvenience over controlChose a tool or place because it was easy or fast.
Storage choicesKeeping it on my own computerChose to keep files local to keep control.
Institutional rulesEthics form as the minimumTreats the approval wording as a floor, not a limit.

Inductive and deductive codebooks

  • Inductive: codes come from the data. You read, then name what you see. This suits exploring something new.
  • Deductive: codes come from a theory, an earlier study or your research questions. You apply them to the data. This suits testing or extending existing work.
  • Hybrid: you start with a few deductive codes and add data-driven ones as you go. This is common and works well.

Merging, splitting and retiring codes

SituationWhat to do
Two codes are used for the same ideaMerge them and record which name you kept
One code covers two different ideasSplit it and recode the passages
A code is never usedRetire it, and note why
A code is used for everythingIt's probably too broad; split it or sharpen the definition
Coders keep disagreeing on a codeImprove the definition and add near-miss examples

Agreement between coders

When two or more people code, some studies measure how often they agree, using percent agreement or a statistic such as Cohen's kappa. Others avoid this. Braun and Clarke argue that reflexive approaches don't need coder agreement, because the aim is a richer, researcher-built interpretation, not a single correct coding. Choose what fits your method, say what you did, and explain how disagreements were settled.

Codebook checklist

  • Every code has a name, a definition and an example.
  • Each code says when to use it and when not to.
  • I tested the draft on real transcripts.
  • Disagreements led to clearer definitions.
  • The codebook has a version number and a change log.
  • I can explain how it was built in my methods section.

Next, record your thinking alongside the codes in analytic memos.

Frequently asked questions

How many codes should a codebook have?

There is no right number. Use as few as you need to answer your questions, and few enough that you can remember them. Many studies end with a few dozen. The size depends on your data and your method.

Can I change my codes halfway through?

Yes, and you usually should. Record each change, and recode earlier transcripts so the whole data set is coded the same way.

Do I need a codebook if I'm working alone?

It's not required, but it helps. It keeps your own meanings steady and gives you something to show a supervisor or reviewer.

What is the difference between a code, a category and a theme?

A code labels a passage. A category groups related codes. A theme is an idea that runs through the data and answers your question. Codes come first and themes come last.

Keep reading