iCloud Photo Library is an optional feature on iPhone, iPad, iPod touch and Mac that uploads every photo and video you take or import to iCloud and keeps everything synchronized across all your Apple gear. I’ve been using it for years and it really “just works”.
On iOS 10 and earlier, Photos syncs with iCloud each time your device connects to Wi-Fi and the battery is charged. On iOS 11 and later, Photos can also use your iPhone’s cellular data connection to sync and update the image library.
Do you take many photos on the go? Are you on a metered rather than an unlimited plan? Then you don’t need me to tell you that you must ensure you’re not wasting huge amounts of cellular data to this feature.
Here’s how to stop the Photos app from eating into your iPhone’s cellular data plan.
Before we get to it, keep in mind the following:
  • iOS 10 and earlier—Your Photos library syncs with iCloud each time your device connects to Wi-Fi and the battery is charged.
  • iOS 11 or later—Your decide if Photos syncs with iCloud via cellular or Wi-Fi only.
In other words, you should double-check that cellular updates for iCloud Photo Library are turned off only if you’re on iOS 11 or later. Folks on older iOS editions needn’t do that because Photos syncs with iCloud only when their iPhone is connected to power and Wi-Fi.

How to stop iCloud Photo Library on iPhone from using cellular data

12-megapixel images and 4K videos captured on your iPhone take up quite a bit of storage space. For most people, there’s no point allowing iOS to gobble up cellular data just to keep the image library synchronized with iCloud at all times.
Thankfully, you can prevent this from happening, and here’s how:
1) Launch the Settings app on your iPhone or cellular iPad.
2) Tap Photos in the list.
3) Tap Cellular Data.
4) Slide the button labeled Cellular Data to the OFF position.
This device will no longer use your carrier’s cellular data for updating the Photos library. Any changes to your image library will automatically upload to iCloud as soon as the device connects to power and Wi-Fi.
TIP: If you really need Photos to be in perfect sync with iCloud at all times, even on the go, via cellular and Wi-Fi, be sure to slide the toggle labeled Unlimited Updates to the OFF position.

The feature’s description says “unlimited updates may cause you to excess your quota“.