
Executive Function Tasks
Executive function tasks measure the goal-directed control processes that let people inhibit automatic responses, update information held in working memory, shift between rules, and plan multi-step actions.
This page groups Labvanced's executive function task templates by the component they measure, compares them, and links to each task's full setup page.
Table of Contents
Executive Function Components and Their Corresponding Tasks
A. Inhibitory Control
Inhibitory control is the ability to suppress an automatic or dominant response in favor of a less automatic, more appropriate one (Diamond, 2013).
Stroop Test
Participants view color words presented in congruent or incongruent font colors and must respond based on the text color rather than the word meaning.
- Implementation: Counterbalance congruent and incongruent trials, include a practice block before scored trials, and record both reaction time and accuracy. Read more →
- Data output: Reaction time (congruent vs. incongruent trials), accuracy, and the Stroop interference effect (incongruent RT minus congruent RT). Read more →
B. Working Memory Updating
Working memory updating is the ability to hold information in mind and continuously revise it as new information arrives, rather than simply storing a static set (Diamond, 2013). Across all three tasks below, keep inter-trial intervals consistent, since they affect perceived load.
N-Back Task
Continuous updating under a fixed cognitive load.
This task examines working memory capacity using the 2-back task. Participants complete a series of trials where they must indicate if the current stimulus matches the one presented two steps earlier. Training trials and immediate feedback are provided to support learning and engagement.
- Implementation: The built N-Back template runs the 2-back version, with desktop and mobile variants and match/non-match response mapping counterbalanced across participants. Read more →
- Data output: Hit rate and false alarms. Read more →
Digit Span Task
Verbal working memory capacity, forward and backward spans.
This study measures verbal working memory using the Digit Span Task. Participants recall digit sequences of increasing length in the same order they were shown or in reverse order. Accuracy, reaction time, and the longest span successfully recalled are captured as performance indicators.
- Implementation: Increases sequence length progressively until the participant's span limit is reached. Read more →
- Data output: Longest span successfully recalled, accuracy by sequence length. Read more →
Corsi Block Tapping Test
Visuospatial working memory capacity.
Blocks flash sequentially on screen. Participants must repeat the sequence by clicking the blocks in the exact order shown.
- Implementation: Increases sequence length progressively until the participant's span limit is reached. Read more →
- Data output: Longest span successfully recalled, accuracy by sequence length. Read more →
C. Cognitive Flexibility and Set-Shifting
Cognitive flexibility is the ability to shift between rules, tasks, or mental sets, often in response to changing demands or feedback (Diamond, 2013).
Card Sorting Test
Rule discovery and perseveration after an unannounced rule change.
In this task, participants sort cards based on different rules. The rules will change during the task without being announced and the participant needs to figure out the new rules from feedback.
- Implementation: The sorting rule can change at any time without warning; participants must infer the new rule from feedback alone. Read more →
- Data output: Perseverative errors and categories achieved. Read more →
Trail Making Test
Alternating between two ordered sequences (numbers and letters) in Part B.
In Part A, the participant connects numbers in ascending order (1-2-3...) while in Part B, numbers and letters alternate (1-A-2-B...), in this classic task for measuring cognitive flexibility.
- Implementation: Part A (numbers only) provides a baseline to isolate Part B's switching cost from general psychomotor speed. Read more →
- Data output: Completion time for Part A and Part B, and switch cost where a rule change is isolated from baseline performance. Read more →
D. Planning
Planning is the ability to sequence a series of steps toward a goal before acting, rather than solving a problem through trial and error (Schumacher et al., 2025).
Tower of London Test
This study measures planning and executive function using the Tower of London Test. Participants rearrange colored balls across three pegs to match a target configuration in as few moves as possible. Initial thinking time, movement execution time, and accuracy against the optimal solution are captured as performance indicators.
- Implementation: Separate initial thinking time from movement execution time, and compare moves taken to each problem's optimal solution, since efficiency matters alongside reaching the target configuration. Read more →
- Data output: Initial thinking time vs. movement execution time, moves taken vs. the optimal solution, and rule violations (illegal moves). Read more →
Implementation Best Practices
Running executive function tasks online or in-lab involves a few shared setup details that affect data quality across any cognitive control task, regardless of which component it measures.
- Maintain precise, millisecond-level stimulus timing using Labvanced's Precise Timing capabilities, especially for reaction-time-based measures like the Stroop Test and N-Back Task. Labvanced's stimulus timing is grounded in peer-reviewed methods for precise JavaScript display timing (Lukács & Gartus, 2022)
- Counterbalance trial order and condition assignment to control for practice and fatigue effects
- If the task paradigm allows for it, consider including a practice block with a performance threshold before scored trials begin
- Keep instructions and stimulus presentation consistent across desktop and mobile administration
- Collect both reaction time and accuracy wherever both are meaningful, rather than accuracy alone
Related Technologies
Executive function studies often pair these tasks with other Labvanced capabilities, whether that's adding gaze data to a planning task, collecting a self-report measure alongside a performance task, or moving a battery in-lab.
Webcam Eye Tracking
Add gaze data to a planning or flexibility task without extra hardware, using built-in, code-free, peer-reviewed webcam eye tracking.
Questionnaires
Pair an executive function task with a validated self-report instrument in the same study, no separate survey tool required.
Desktop App
Run the same battery in-lab, with EEG or other LSL-connected hardware integration.
Example Study Setups
Executive function research can combine several tasks into a battery, or focus on a single component, depending on the study's scope. The example study setups below show common executive function combinations and standalone setups built from the tasks above.
Single-Component Study
A focused design that measures just one component, the right starting point when the study only needs a single construct rather than a broad profile. The Stroop Test alone, for example, isolates inhibitory control without the setup time of a full battery. The same logic applies to running just the Tower of London Test for planning, or just the N-Back Task for updating. Import whichever task matches the component you need, or build your own if none of the seven above fits your stimulus set.
Updating Battery
N-Back Task, Digit Span Task, and Corsi Block Tapping Test together give three converging measures of working memory, useful when a single task's score might reflect stimulus-specific noise rather than updating ability itself. Running all three strengthens any claim about working memory specifically, since the result no longer depends on one stimulus format. Import a selection of these three tasks, or build your own updating task to add to the mix.
Flexibility and Planning Battery
Card Sorting Test, Trail Making Test, and Tower of London Test together cover set-shifting and planning in one session, a common pairing in clinical and developmental batteries. Each task isolates a different angle on flexibility, from unannounced rule changes to alternating sequences to multi-step planning. Import a selection of these three tasks, or build your own flexibility or planning task to add to the mix.
Full Executive Function Profile
One task per component, Stroop Test, N-Back Task, Card Sorting Test, and Tower of London Test, gives a broad executive function profile without duplicating any single component. This setup suits studies that need to characterize executive function broadly rather than drill into one process. Import this selection of four tasks to start, or build your own task to add a fifth component or strengthen one you've already included.
Frequently Asked Questions
What's the difference between an inhibition task and a cognitive flexibility task?
Which executive function task measures working memory?
Can I combine multiple executive function tasks in one study?
Do these tasks run the same way online and in-lab?
References
Diamond, A. (2013). Executive functions. Annual Review of Psychology, 64, 135-168. https://doi.org/10.1146/annurev-psych-113011-143750
Lukács, G., & Gartus, A. (2022). Precise display time measurement in JavaScript for web-based experiments. Behavior Research Methods. https://doi.org/10.3758/s13428-022-01835-2
Schumacher, L. V., Rahm, B., Kaller, C. P., Schyle, V., Weiller, C., & Unterrainer, J. M. (2025). A novel index to measure pre-planning in the Tower of London task: Test-retest reliability and known-group validity. British Journal of Psychology, 117(3), 1007-1025. https://doi.org/10.1111/bjop.70044