Syncing through the photos app will be easiest. But, you’ll need to disconnect from iCloud and/or create a new library after syncing otherwise images you delete will delete on your Mac too.
this is what I would do:
turn on iCloud Photos on your Mac. Be sure optimize is not enabled. Set up and use iCloud Photos - Apple Support
let the sync happen
Once all of your images are on the Mac, disable iCloud Photos on the Mac. This will allow you to keep the current images in one photo library.
backup your Mac
just remember, if you delete files in iCloud and turn sync back on, you’ll lose files.