Check the battery health.
iPhone batteries also age with the devices. They can only handle a certain number of charge cycles before the battery health starts to dwindle. Apple tried to combat poor battery performance by offering a
A good rule of thumb is to check the battery health on a device running iOS 11.3 or later by going to Settings > Battery > Battery Health. This can help you know whether or not you’ll need a battery replacement in the near future.