A jsPsych breathing exercise implementation created to assist users in carrying out deep breathing techniques, with relevant applications across personal mindfulness practice and research paradigms.
Caution
If you begin to experience dizziness, air hunger, pain, or any other adverse effects when practicing deep breathing techniques, immediately STOP engaging with the exercise.
The primary reason for wanting to code this implementation was to produce reliable breathwork exercises to be used in a controlled research environment.
- Users are provided with distinct exercises to choose from (more on this under the next heading)
- For each exercise, users are given different lengths to select from
- Instructions are provided on how to effectively engage with each exercise within the parameters of this technology-assisted setup
- In each breathing exercise, a real time countdown sequence is provided for every step of the cycle
- This implementation is available via an easily-accesible webpage!
There are two different lengths of 4-7-8 breathing included: 4x cycles and 8x cycles. If you are a novice to this breathing practice, it is strongly advised that you start out with the 4x cycles version. This is due to the likelihood of experiencing adverse physiological side effects (dizziness, fainting, discomfort) when undertaking 8x cycles due to the strong parasympathetic intensity of 4-7-8 breathing.
A representation of one cycle of 4-7-8 breathingThere are four different lengths of box breathing included: short (2 minutes), medium (5 minutes), long (10 minutes), and longer (20 minutes). If you are new to box breathing, it is suggested that you start out on either the short- or medium-length exercises.
A representation of one cycle of box breathingThere are four different lengths of 7-11 breathing included: short (2 minutes), medium (5 minutes), long (10 minutes), and longer (20 minutes). Just like with box breathing, if you are new to deep breathing practices, it is suggested that you start out on either the short- or medium-length 7-11 exercises.
A representation of one cycle of 7-11 breathingAt least three possible drawbacks of using this implementation can be identified, which may contribute to an attenuation of the benefits of engaging with breathing exercises:
- Firstly, this implementation "counts" the steps included in each exercise cycle for the user. It may be that the action of counting each step by oneself is actually an important component of engaging with breathing techniques
- Second of all, mindfulness practices are typically utilised in an endeavour to escape stimulation and the fast-paced nature of one's external environment. If breathing exercises are performed using a computer, and especially in a lab environment, this may not provide a setting conducive to reducing such stimulation. Relatedly, it could also be that watching these counts is suboptimal, where otherwise closing one's eyes may produce more favourable outcomes
- Thirdly, this implementation encourages the user to sit down whilst performing their deep breathing. This neglects those who may prefer to lay down or stand up whilst engaging in mindfulness
If any issues occur within this implementation, please open an Issue so that any problems highlighted can be addressed. Thank you!


