iCloud Photo Library works seamlessly with the Photos app to upload all your photos and videos to iCloud, so you can access them on all your devices.

iCloud Photo Library lets you access all the photos and video in the Photos library on your Mac anytime, anywhere. And any photo or video you take appears on all your devices automatically, organized the same way on every device. Your original, full-resolution photos and videos are stored in iCloud, and you can optimize the storage space on your Mac by keeping smaller versions on your Mac. You get 5 GB of iCloud storage for free and additional storage space is available, starting at 20 GB for just $0.99 per month.
For information about setting up iCloud Photo Library, see Access your photos and videos everywhere with iCloud Photo Library.