My heart start pounding irregularly mainly when I lay flat in bed and sometimes when I just sit could this be somthing bad. I am 27 on overweight.?

Need a heart monitor. You should have a heart monitor to find out what type of heart rhythm you are actually having when you feel the irregularity. If you have something called atrial fibrillation it is important to get appropriate treatment. Please see your doctor about this.
It could - You may have arrhythmia that is transient due to a certain strain or stress to the heart -- it could be due to electrolyte imbalance or oxygen perfusion or pressure load problem -- please see your doctor!