Many psychologists spend hours setting up surveys in Qualtrics (the standard survey tool in academic research): clicking through menus, copy-pasting question text, manually configuring randomization blocks. If you have multiple counterbalanced conditions, it can take an entire afternoon.
You can skip all of that. Connect Claude Code to the Qualtrics API, give it your study design doc, and it builds the full survey: blocks, questions, embedded data, randomization, piped text, content validation, everything. My collaborator and I set up multiple studies this way. Each took about 5 minutes to create and another 5-10 minutes of back-and-forth tweaks. It basically replaces the need for a research assistant to set up your surveys and saves you hours of manual work.
How to set it up
I recommend doing all of this with Claude Code CLI.
Step 1: Get your Qualtrics API token. Log into Qualtrics, click your profile icon, then Account Settings, then Qualtrics IDs. Copy your API Token and note your datacenter from the URL (e.g., iad1 if your URL is iad1.qualtrics.com).
Step 2: Tell Claude to store your credentials so it remembers them across sessions. You can put them in a CLAUDE.md file in your project folder.
Step 3: Give Claude your study design and ask it to create the survey. Something like:
Here is my study design doc [link or paste]. Create this as a Qualtrics survey using the API. Include all questions with export tags matching my variable names, descriptive block names, and the counterbalancing scheme described in the doc. Keep all text 1:1 identical to the doc. Do not change any wording.
Claude writes and executes the API calls, handles errors, and gives you a link to the finished survey. If you’re unsure about any step, just ask Claude. It can walk you through the whole process.
Tips
Tell Claude to keep text 1:1 identical to your design doc. Otherwise, it may “improve” your wording. Be explicit: “Do not change any text.”
Work from a detailed design doc. The more specific (variable names, scale anchors, counterbalancing, piped text), the fewer rounds of fixes.
Use Claude to verify consistency. After creating the survey, ask it to pull the survey back from Qualtrics and compare every question word-for-word against your doc, including your pre-registration. It catches discrepancies you’d miss.
Build on previous surveys. When creating a new study, tell Claude to copy an existing Qualtrics survey and use it as a baseline. It preserves the consent block, flow logic, and settings, so you only need to update what has changed.
Iterate via chat. When your collaborator sends feedback or adds comments to your doc, just paste it into Claude and ask it to implement the feedback.
(Claude Code wrote most of this post, right after setting up some Qualtrics studies for me.)


