First, consider pleurisy, if there is inflammation in the pleural area. It will stimulate and cause pain, then you should go to the hospital for relevant examination to clarify the diagnosis, you can take non-steroidal anti-inflammatory drugs, such as indomethacin, diclofenac sodium, etc. Secondly, respiratory diseases, such as lung cancer and tuberculosis, can also cause pain, so you should go to the hospital to perform a lung CT to make a clear diagnosis and then treat the symptoms. Third, because the right side of the rib cage is under the liver, so we should also exclude the possibility of liver disease.