It is always difficult from mere descriptions of symptoms to tell whether a (likely painful) trip to the emergency department is warranted, so I would suggest that you speak with your primary care physician
. Upper back pain might be a simple muscle cramp or possibly pain coming from the spine. Pain that is worse when you breath deep could be due to inflammation of the outer lining of the lung which when irritated makes it hard to take a deep breath. Pain that is derived from an inflamed gall bladder or pancreas usually causes abdominal pain, but often this pain radiates to the back or even the scapula. Pain from gall bladder disease can also be worse with a deep breath as your describe.
Without knowing more about this problem, I would suggest that you schedule an appointment with your primary care physician. If the pain is severe enough, go the ED. The first step is to have your upper back examined to find out where the pain is. If the pain is thought to be pleurtic in nature, your doctor
might get a chest x-ray
. If it is thought to be due to gall bladder disease, then your doctor will likely want to order an abdominal ultrasound. Finally, if this is thought to be something else in the abdomen, then a CT scan might be needed. Good luck.