As per this article https://support.apple.com/en-in/HT204570
What happens when I go over my iCloud storage limit?
If you exceed your iCloud storage limit, photos and videos won't upload to iCloud and your library won’t stay up to date across your devices. To continue using iCloud Photos, upgrade your storage plan or reduce the amount of storage that you're using.
Reduce the storage for iCloud Photos by deleting photos and videos that you don't want to keep from your iOS devices or on iCloud.com. Your device will immediately remove any photos and videos that you delete and they won't be available for recovery in your Recently Deleted album.
If you're out of storage, your devices won't back up to iCloud, and new photos, videos, documents, and your information won't stay up to date.
See this https://support.apple.com/en-in/HT205966
Back up your library - in future if the photo data exceeds .
Before following any of these steps, it's a good idea to create a backup of your photo library, even if you use iCloud Photos. You can use Time Machine, use a third-party backup solution, or copy the library to an external drive. By default, your photo library is stored in the Pictures folder within your home folder.