You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

How can I remove 300 groups from my iCloud Contacts?

My OS X Address Book started out with about 10 groups, but now iCloud.com has about 300 groups.


The replication arose because of a bug in how iCloud handles a mixture of Address Book Cards with both OS X and Windows line terminated Notes (LF vs. CRLF - it helps if you once used a typewriter).


I figured out how to convert Address Book to all LF terminated line feeds and I was able to get iCloud.com working on a different account, but my core account is stuck with 300 groups (some replicated 50 times).


I know how to delete all Cards/Contacts in iCloud.com Contacts, but, unfortunately that doesn't remove Groups. (Groups have an interesting behavior in iCloud, almost as though Apple has a special plan for them.)


I can delete Groups one at a time on iCloud.com, but that's tedious. Unfortunately deleting them on Address Book, and trusting in sync to clear up iCloud.com, is equally tedious.


Has anyone heard of a way to delete all Groups on iCloud or Address Book 6? Perhaps an AppleScript?


Has anyone heard of Apple resetting a corrupt iCloud account to clear out bad data? (I have a clean version of Address Book I can use to restart -- that, by the way, is harder than you'd think. Again because Groups are special).


Advice appreciated. If I get some free time I might take may laptop by the Genius bar and see what they say...

Posted on Jul 7, 2012 7:41 PM

Reply
21 replies

Apr 8, 2017 1:45 PM in response to jfaughnan

This is still a HUGE Problem for me-it is 2017---is this fixed yet? I have never done 'CODE' so can someone speak in Language a Non Computer person can understand? How does a person run code? What application do I open-It sounds like the Answer--Problem is...how to execute....needs more breaking down...for those of us--already overloaded w/New Applications daily-Thanks

Jul 13, 2012 6:20 PM in response to jfaughnan

I apologize for jumping in, as I don't have an answer -- I found this because I have the same problem. I did want to clarify something, however: If I have to hand-delete a mass of groups (not as many as yours, but 100+), I am guessing that I should change the default address book to wherever I am deleting. Currently I have the iCloud version as a default, but I can't find where to even manually delete groups there..


I hope you get your answer -- I've subscribed to this tread just in case.

Jul 16, 2012 10:32 AM in response to jfaughnan

I have exactly the same problem.


I use iClud as default in all my devices and they all show the same contacts, including the groups. I dont have duplicate contacts, but hundreds of empy groups (groups with no name). It seems that an empty group replicates several times a day. I dont know how to stop this replication process and, additionally, I dont know how to remove hundreds of groups (apart from one at a time).


Any help will be greatly appreciated.

Jul 16, 2012 8:40 PM in response to jacabeza

I'm sorry to say that in this case misery loves company. These reports tell me that sooner or later someone with programming chops or clout will get this bug and do something.


In my case it's not a priority -- I've given up on iCloud and Lion both and I kept my iMac on Snow Leopard. I'm back to synchronizing my Address Book with my iPhone via iTunes cable (it still works, still is the most reliable way to sync).


I'm going to try Mountain Lion on my MacBook Air and see if that provides any fixes, otherwise I'll wait and see if Apple fixes iCloud. I won't move my main machine to Lion, and I'll hold off going to Mountain until this bug is fixed.

Jul 26, 2012 5:32 PM in response to jfaughnan

I figured this out. In this case I didn't care about my Contacts, I had them elsewhere. My problem was my iCloud acount was "poisoned" with massive replication of 'Groups'. Even after I deleted all the Contacts I still had hundreds of Groups to get rid of. Manual deletion was too tedious.


The answer was a simple AppleScript (I'm on ML on the machine i ran this on, so it's "contacts" rather than Address Book:


tell application "Contacts"

repeat 50 times

set theGroup to group "MyGroupName"


deletetheGroup

end repeat

save

end tell


Since I had the same Group Names replicated about 100 times each, I only had to run this about 10 times to clear them all out. When I got to smaller numbers I had to drop the repeat count. I changed the Group name as I went.


Took me about five minutes.


I'm sure an AppleScripter could turn this into a general script for removing all groups all at once. Or could get very clever, and only remove groups that had no contacts (so one could salvage the group/contact relationships).


I didn't need that. My problem has been fixed.


I think sync works a LOT better in ML than Lion btw. iCloud updated very quickly.

Aug 29, 2012 1:21 PM in response to jfaughnan

I had a similar problem (Lion OS X). Hundreds of duplicates of 3 Groups. Was driving me nuts trying to work a way of deleting them.


For the record, my problem started when I created multiple tags in Cobook which syncs with Address book. These tags create Groups in Address Book.


The script sorted it in 15 mins once I'd worked out how to use it. Thanks jfaughnan!


Steve

Jan 14, 2013 11:50 AM in response to jfaughnan

jfaughnan,


I have run scripts in setting up OpenGL programs on my Macs. I cannot get your script to execute, however, and have tens of thousands of "untitled group"s in my contacts in the cloud. Does each line in the script need to be entered separately into Terminal, all in one line, or something different yet? Please advise.


Lee

May 16, 2013 9:05 AM in response to jfaughnan

The script works. It turns out I had over 10,000 of these untitled groups, as a result of trying to get these groups out of several devices and re-syncing over and over. Don't do that. Do this...

1 - MUST have ALL devices set to sync the Contacts with icloud - iCloud Contacts turned on.

2 - don't run any apps or use the internet while doing this - it really slows down the response time of everything.

3 - run the script on your computer that has the contacts as many times as it takes until it tells you if is unable to find the groups you are trying to delete. You may have to adjust the number you are wanting to delete to a lower number when it gets close to the end. You know you are close because the script runs much faster towards the end.

4 - give it a lot more time to sync with all the devises - just walk away. I went to bed and the next day all the untitled groups were gone from all devices, my computer and my iCloud account.

This script did not run on 10.7.5, but worked fine in 10.8.3

How can I remove 300 groups from my iCloud Contacts?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.