How to code the open-ended responses of a survey, in 5 steps
Read the responses and choose the question
Before coding, read a sample of the responses. Work on one open-ended question at a time.
Build the codebook
With that sample, build between five and ten categories. Each one gets a name, a short definition, an example and a rule for doubtful cases. The categories should cover all the responses and overlap as little as possible.
Assign each response to a category
Assign each response to a category. A response can fall into more than one category if your codebook allows it.
Review the categories and measure agreement
Look at how each category worked: how many responses it proposed, how many you accepted and how many you rejected. One you reject a lot is badly defined: refine its definition, merge it with another or drop it. So that someone else can repeat your work, measure the agreement between two coders (how to measure intercoder reliability).
Bring the categories into your dataset and document
Paste the categories into your dataset as variables: one column per category. Document the codebook, how you assigned the responses and how much you reviewed.
Other ways to do it
You can do it by hand in a spreadsheet (one row per response and one column per category), with qualitative analysis software such as NVivo, ATLAS.ti or MAXQDA, or with a script.
HILO is the better fit for a quick first pass: it runs in the browser, there’s nothing to install and, without AI, it’s free and needs no sign-up. Another tool is the better fit for large projects, teams with several coders, or analysis that goes beyond counting categories.
Code your own responses
Upload your spreadsheet, pick the open-ended column and review the categories.
Updated
More guides
How to measure intercoder reliability
Cohen’s kappa in 5 steps: code separately, build the table, count the agreement, remove chance and report.
How to share a dataset without exposing personal data
Column inventory, what to do with each one, free text, re-identification risk and the code table, in 5 steps.
How to clean a survey dataset before analyzing it
Read the file correctly, find repeats, check columns, spot non-response codes and fix at the source, in 5 steps.
How to merge two survey datasets
Choose between stacking and joining by identifier, check that they measure the same thing, merge and review the result, in 5 steps.
How to operationalize a project’s objectives with your variables
Write the objectives, take stock of the variables, match them, define indicators and recognize what’s missing, in 5 steps.