2 tests:
1) drain to !, then plug in. then start a timer. check it until it's 100%
2) drain to !, then power off, and then plug in. start a timer. check until it's 100%.
if takes longer to charge while still powered on, then something is draining it while it's charging. i.e. - something running in the background that doesn't allow it to charge as efficiently. to find out if something you installed or a core program...
drain until red but not quite !, then reboot into safe mode (hold power, long press power off, select to reboot into safe mode). once powered back on, plug in, start a timer...
if it charges ok, then a 3rd party app is causing issue. if it STILL doesn't charge well, then it's time for a factory reset as something with the main programming isn't running right.