Home > Mac administration, Mac OS X, Scripting > Disabling the iCloud sign-in pop-up message on Lion and later

Disabling the iCloud sign-in pop-up message on Lion and later

Starting in 10.7.2, Apple set the iCloud sign-in to pop up on the first login.

10.7.5 iCloud pop-up message

Screen Shot 2013-10-27 at 9.00.38 AM

10.8.5 iCloud pop-up message

Screen Shot 2013-10-27 at 9.02.29 AM

10.9.0 iCloud pop-up message

Screen Shot 2013-10-27 at 9.04.27 AM

Since having this appear may not be desirable in all Mac environments, it makes sense to be able to turn this off for new user accounts. As part of preparing for Mavericks in my own shop, I’ve developed a script that should disable the iCloud pop-up on 10.7.2 – 10.9.0. See below the jump for the details.

Apple is using /Users/username/Library/Preferences/com.apple.SetupAssistant.plist to store the settings that indicate whether or not the iCloud sign-in process has run. Building on work done by the folks behind DeployStudio, I’ve built a script that pre-sets those values for new and existing accounts on a particular Mac. In turn, that should stop the iCloud pop-up message from appearing on that Mac.

Update – 10-30-2013: It looks like setting the following values are not needed to block the iCloud pop-up:


I’ve updated the script to remove the parts that referenced setting those values.

The script is below and is also available on my GitHub repo.

  1. October 29, 2013 at 11:54 am

    Curious if you know the nature of LastPreLoginTasksPerformedVersion and LastPreLoginTasksPerformedBuild? I’d guess these might be the things that are running when you see the “Completing setup..” animation. There might be good reasons to leave these alone if they aren’t related to iCloud and/or don’t require user interaction.

    In my tests doing re-imaging and upgrade installs of 10.9, I haven’t needed these and have instead simply updated my Configuration Profile to have a LastSeenCloudProductVersion of ‘10.9’.

    • October 29, 2013 at 2:52 pm

      I don’t know the exact nature of the LastPreLoginTasksPerformedVersion and LastPreLoginTasksPerformedBuild values, but I tried running my script without those values and got the iCloud pop-up message even when the script was inserting LastSeenCloudProductVersion “${sw_vers}” into com.apple.SetupAssistant.plist.

      With those values added, the iCloud pop-up message did not appear.

      • October 29, 2013 at 9:35 pm

        Hmm. I also am only setting DidSeeCloudSetup to True and LastSeenCloudProductVersion to “10.9” and the iCload/AppleID Setup Assistant is not appearing.

  2. October 30, 2013 at 6:41 pm

    I’ve re-tested and it looks like the LastPreLoginTasksPerformedVersion and
    LastPreLoginTasksPerformedBuild do not need to be set after all. Thanks for the heads up!

  3. October 31, 2013 at 12:38 pm

    You could do this … or you can rename the minilauncher file. For example: mv -f -v /System/Library/CoreServices/Setup\ Assistant.app/Contents/SharedSupport/MiniLauncher /System/Library/CoreServices/Setup\ Assistant.app/Contents/SharedSupport/MiniLauncher.backup

  4. seabash
    November 21, 2013 at 4:33 am

    Thanks for sharing (as always), Rich.
    It’s working as-is for me on 10.7-10.9 Macs.

    I am seeing a directory created at /Users/root.
    The the root user is not actually being enabled from this script and we. I know root homedir actually resides at /private/var/root, and “no”, we do not explicitly enable root user in our environment.

    Has anyone else seen this?

    Might this be due to fact that…
    A. We use < 500 UIDs for local admin accounts
    B. No accounts exist in 501-1023 (at least on newly-imaged and AD-bound Macs)
    C. Our AD account UIDs are in the 9-digit range

    • sammynole
      November 21, 2013 at 10:11 pm

      @seabash I am debating upgrading our educational lab environments from 10.8.4 to 10.9. We haven’t had any issues with the AppleID previously for our users using their AD accounts to login. Is the iCloud issue going to persist even if the computer is joined to AD?

  5. January 22, 2014 at 3:07 pm

    Hi Rich! I must be doing something wrong with this script? I’ve been trying to deploy it with Casper and run it with a command and I’ve tried to just upload the script to the JSS and then run it from there in a policy but I’m still seeing the “Sign in with you AppleID” message on all new user accounts. Do you have any suggestions on what I might be doing wrong?

  6. Mark Spidle
    March 7, 2014 at 4:01 pm

    Rich, how do you use this script with DeployStudio? I’ve tried running it as is after a restore, or during a restore and neither seem to work.

  7. March 17, 2014 at 9:15 pm

    Why this scripy dies not work. After OS upgrade via FileWave, iv kept this in the same folder group and it gets installed right after OS is upgraded from 10.8 to 10.9 but still every user when logs in, get the iCloud prompt. Anything special needs to be done?

  8. Lars
    May 29, 2014 at 11:04 pm

    So, I’ve been banging my head against this problem off and on (while doing other stuff) for a couple weeks now. I was so excited when I found a simple script that would do it for me, only to become even more aggravated when it didn’t work. However, in this moment, I am euphoric. It must be a difference in 10.9.2 or something, I’m not sure since I don’t have any 10.9.0 or .1 installs available, BUT… my problem was I couldn’t find the location the script was trying to look at. Turns out, I had to put “/Non_localized” in front of the path to the plist file of the user template.

    In short, change lines 18, 19, and 20 to look like this:
    defaults write “${USER_TEMPLATE}”/Non_localized/Library/Preferences/com.apple.SetupAssistant DidSeeCloudSetup -bool TRUE
    defaults write “${USER_TEMPLATE}”/Non_localized/Library/Preferences/com.apple.SetupAssistant GestureMovieSeen none
    defaults write “${USER_TEMPLATE}”/Non_localized/Library/Preferences/com.apple.SetupAssistant LastSeenCloudProductVersion “${sw_vers}”

    Also, as a side note, my colleague tried using rjpurves’ solution, and found it to work as well.

  9. sally
    September 26, 2014 at 6:18 pm

    Is there anyway to get rid of the icloud pop up for those of us that are not so technically inclined?

  10. A-bomb
    October 21, 2014 at 1:06 am

    I love you Rich.

  11. November 16, 2014 at 3:53 pm

    any non-tech savvy help would be appreciated — this icloud login pop up just started last week and since i run a lab at school — it will freak the third graders out when this pops up unexpectedly!!

    Macbook Pros 2012 running 10.9.5
    MacBooks 2008 running 10.9.5

    thanks for any help

    ** I’m a tech teacher because i was crazy enough to open a Net Day Box and ask what does this do in 1996!!

  12. Michael Carey
    June 3, 2015 at 3:43 am

    We have a bit of a fringe case, using PBIS Open for AD authentication against multiple domains, where only one domain doesn’t require a domain prefix. The script worked great for that one domain and any local accounts, but broke for accounts from any other prefixed domain. I fixed it by using numeric UIDs read from the home directories, instead of the names of the home directories themselves. It’s a two-line change, so that:

    USER_UID=`basename “${USER_HOME}”`
    if [ ! “${USER_UID}” = “Shared” ]


    if [ ! “${USER_HOME}” = “/Users/Shared” ]; then
    USER_UID=`stat -r ${USER_HOME} | awk ‘{print $5}’`

    The ‘chown’ command is quite happy using the numeric UID, and it works across all domains.

  13. Nate Carlsen
    July 14, 2015 at 9:54 pm

    Anyone getting this to work with 10.10.4? If not, what do we need to adjust in the script to get this to work with 10.10.4?

  14. wolf
    July 23, 2015 at 7:05 pm

    I have no problem running it on 10.10.4 but under every OS Ive tried it produces the following error “chown: Deleted Users: illegal user name” which is just annoying but not work stopping

  15. NightFlight
    September 8, 2015 at 4:53 pm

    Some optimization

  16. NightFlight
    September 8, 2015 at 4:53 pm

    #!/bin/sh -x

    # Determine OS version
    osvers=$(sw_vers -productVersion | awk -F. ‘{print $2}’)
    sw_vers=$(sw_vers -productVersion)

    # Checks first to see if the Mac is running 10.7.0 or higher.
    # If so, the script checks the system default user template
    # for the presence of the Library/Preferences directory.
    # If the directory is not found, it is created and then the
    # iCloud pop-up settings are set to be disabled.

    if [[ ${osvers} -ge 7 ]]; then

    for USER_TEMPLATE in “/System/Library/User Template/English.lproj” “/System/Library/User\ Template/French.lproj”
    if [ ! -e “${USER_TEMPLATE}/.LastSeenCloudProductVersion_${sw_vers}” ]; then
    defaults write “${USER_TEMPLATE}”/Library/Preferences/com.apple.SetupAssistant DidSeeCloudSetup -bool TRUE
    defaults write “${USER_TEMPLATE}”/Library/Preferences/com.apple.SetupAssistant GestureMovieSeen none
    defaults write “${USER_TEMPLATE}”/Library/Preferences/com.apple.SetupAssistant LastSeenCloudProductVersion “${sw_vers}”

    touch “${USER_TEMPLATE}/.LastSeenCloudProductVersion_${sw_vers}”

    for USER_HOME in /Users/*
    USER_UID=`basename “${USER_HOME}”`
    if [ ! “${USER_UID}” = “Shared” ] && [ ! -e “${USER_HOME}/.LastSeenCloudProductVersion_${sw_vers}” ]; then
    if [ ! -e “${USER_HOME}/.LastSeenCloudProductVersion_${sw_vers}” ]; then
    if [ ! -d “${USER_HOME}”/Library/Preferences ]; then
    mkdir -p “${USER_HOME}”/Library/Preferences
    chown -R “${USER_UID}” “${USER_HOME}”/Library

    if [ -d “${USER_HOME}”/Library/Preferences ]; then
    defaults write “${USER_HOME}”/Library/Preferences/com.apple.SetupAssistant DidSeeCloudSetup -bool TRUE
    defaults write “${USER_HOME}”/Library/Preferences/com.apple.SetupAssistant GestureMovieSeen none
    defaults write “${USER_HOME}”/Library/Preferences/com.apple.SetupAssistant LastSeenCloudProductVersion “${sw_vers}”
    chown “${USER_UID}” “${USER_HOME}”/Library/Preferences/com.apple.SetupAssistant.plist
    touch “${USER_HOME}/.LastSeenCloudProductVersion_${sw_vers}”


  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: