Relationship between posture and neck pain
This article explains why you need to act as if your posture can possibly cause neck pain, although scientific research has not found any compelling evidence.
As you can see in the references below, the correlation between neck pain and body imbalance is not clear. However, the first paper has a small sample and the second paper can be mixed with subjective judgment by physiotherapists who tested the participants. The last one is systematic review where numerous research have been reviewed more extensively, but overall, there is still no clear scientific evidence between pain and spinal alignment.
However, physically and physiologically, it is true that stretched tissues (muscles, tendons) are placed in an environment where it is difficult to contract. If they are exposed to such an environment for a long time, the muscles are likely to become weak and the weakened muscles are prone to get overloaded. The overloaded muscles, in turn, are prone to get tense and eventually, the tensed muscles can cause pain. Again, the painful muscles easily get weaker, hence a vicious cycle.
This also means that they slowly lose their function. Here, the 'function' means a muscle's ability to stretch out and contract again like a rubber band. If the elasticity of a muscle decreases, the muscle can't stretch out at a right time. For example, when you pick up something from the floor, your back and hip muscles all have to elongate while maintaining their force to hold the bony structures in place.
If not, the risk of injury increases and an injury here is a tear in the tissue, which will be followed by an inflammatory/pain response. Therefore, even if scientific research has not found strong evidence, we can deduce that trying to improve postural imbalance can possibly decrease the likelihood of developing pain or sustaining injuries.
References
1. Grob D, Frauenfelder H, Mannion AF. The association between cervical spine curvature and neck pain. Eur Spine J. 2007 May;16(5):669-78. doi: 10.1007/s00586-006-0254-1.
->NO association between neck pain and neck curvature in 107 people over the age of 45.
2. Damasceno GM, Ferreira AS, Nogueira LAC, Reis FJJ, Andrade ICS, Meziat-Filho N. Text neck and neck pain in 18-21-year-old young adults. Eur Spine J. 2018 Jun;27(6):1249-1254. doi: 10.1007/s00586-017-5444-5.
-> NO association between neck pain and “text neck” as assessed by physical therapists.
3. Tarcisio F de Campos, Chris G Maher, Daniel Steffens, Joel T Fuller, Mark J Hancock, Exercise programs may be effective in preventing a new episode of neck pain: a systematic review and meta-analysis, Journal of Physiotherapy, Volume 64, Issue 3.
-> Some studies have found a positive correlation between spinal alignment and pain, but this is exceptions to the rule, and the correlation is not as large as initially estimated. Ergonomic programs do not reduce the risk of a future onset of neck pain, but exercise can halve this risk.