Set custom screensaver - macOS Ventura

New Contributor III

Hi everyone!

I've been spending so much time on this so I hope to find an answer in the Jamf community.
Was anyone able to find a way to set a custom screensaver (a folder with 3 pictures in a loop) that works with macOS Ventura?

I've got close to have it working with the below script, but I still need to manually go into System Settings - Screen Saver and choose "Classic", because it defaults to Ventura and I cannot find a way to fix this.

Any help would be extremely appreciated!




## get current user
user=$( echo "show State:/Users/ConsoleUser" | scutil | awk '/Name :/ { print $3 }' )

## configure screensaver framework
/usr/bin/sudo -u "$user" /usr/bin/defaults -currentHost write moduleDict -dict moduleName -string "iLifeSlideshows" path -string "/System/Library/Frameworks/ScreenSaver.framework/PlugIns/iLifeSlideshows.appex" type -int 0

## set key items for screensaver
/usr/bin/sudo -u "$user" /usr/bin/defaults -currentHost write CleanExit -string "YES"
/usr/bin/sudo -u "$user" /usr/bin/defaults -currentHost write PrefsVersion -int 100
/usr/bin/sudo -u "$user" /usr/bin/defaults -currentHost write showClock -string "YES"

/usr/bin/sudo -u "$user" /usr/bin/defaults -currentHost write CustomFolderDict -dict identifier "/Users/Shared/ScreenSavers/" name "ScreenSavers"
/usr/bin/sudo -u "$user" /usr/bin/defaults -currentHost write SelectedFolderPath -string "/Users/Shared/ScreenSavers/"
/usr/bin/sudo -u "$user" /usr/bin/defaults -currentHost write SelectedSource -int 4
/usr/bin/sudo -u "$user" /usr/bin/defaults -currentHost write ShufflesPhotos -bool "true"

/usr/bin/sudo -u "$user" /usr/bin/defaults -currentHost write styleKey -string "Classic"

/usr/bin/sudo /usr/bin/killall -hup cfprefsd
exit 0




New Contributor II

I'm having the same issue, have you fixed this yet?


New Contributor III

@Abd0192 the script that I posted in the original message ended up working for me in the end, but for some weird reason it doesn't work if you go into System Settings > Screen Saver and make any change before the policy with that script runs.

My suggestion is create a policy with the script, push it on a device, don't make any manual change but just wait until the screensaver starts.

New Contributor II

I've just used your script and it worked. Thank you :)

New Contributor II

I think Sonoma broke this. :( 
has anyone else tested this yet?


New Contributor III

I just tested this, and unfortunately it's no longer working for me either with macOS Sonoma.

Back to square one! :(

New Contributor II

@Manu_ssi  Flipping Apple *_*