Contacts birthday are shown double in calendar

Does executing sync-birthday-calendar with the occ command solve your problems?

./occ dav:sync-birthday-calendar


sadly I have no shell access because it is a webhosting package. is there a possibility to execute this over the
nextcloud website?

It is not directly possible to use occ commands without shell access.
A workaround is proposed in in this discussion, starting from this comment:

I have the same problem – even tripple events. I tried to understand, what happens in the code, but I am not familiar with the DAV API. Sync didn’t help, either.

I think there was an issue about this on the owncloud github, I have to search again and than we should move to github with the conversation.

after some tests i can get database access if I use

‘dbhost’ => ‘’, localhost didn’t work.

so I’m able to run the command

ich@owncloud/htdocs$ ./occ dav:sync-birthday-calendar
Start birthday calendar sync for all users …
2 [============================]

sadly the problem did not solve. I still have to birthday entry’s in calendar.

Mhmm… Is it possible, that you have multiple contacts for one person?
If not, would you mind opening an issue and describe your problem on GitHub:

for me it is solved with deleting the contact birthday calendar.
and let it create new with ./occ dav:sync-birthday-calendar.


i have the same problem with duplicate contacts birthdays and deleted the contacts birthday calender to get rid of the duplicates. but how do you run ./occ dav:sync-birthday-calendar on a nextcloud box? i can ssh to the box (running 10.0.2) but running the command gives no such file or directory

You need to go to the nextcloud directory in your box and zhen issue the command.

that’s /snap/nextcloud/, right? doesn’t make a difference, with or without using sudo.

I am sorry, I don’t know about the folder structure on a nextcloud bix because I don’t have one. Can’t help any further.

You could use the following command to find out where occ is located:
find / -name occ
May take a while until you see a result though…

The Nextcloud Box actually uses the Nextcloud Snap, which has the CLI Utility nextcloud.occ you can call, instead off occ.

1 Like

thanks @eppfel!

for future reference to other nextcloud box users:

  1. delete contact birthdays calendar
  2. ssh into your nextcloud box
  3. run sudo nextcloud.occ dav:sync-birthday-calendar
1 Like

There is another way to get rid of the double entries if the occ doesn’t work as on my NAS:

  1. Create a new adressbook
  2. Export your contacts of your old adressbooks
  3. Delete all the old adressbooks
  4. Delete the birthday-calendar
  5. Create a new adressbook for your contacts
  6. Import the contacts

Finally the calendar is created automatically.

1 Like

How do i delete the adressbook? I can not find a button.

Step 1 of my list!

You must first create one before you can delete the old! Obviously it is not possible to use nextcloud without any adressbook.


But still very confusing to a user that wants to do some migration for some reason. It would be more intuitive if you could delete first and then get a message in contacts that you should first create an addressbook before contacts is usable.



Just to add to this solution - if you removed the contacts_birthday subscription as a user, then you need to re-generate the subscription calendar specifically for that user:
./occ dav:sync-birthday-calendar

Found in:

Hi Micha-Btz,
where did you find the logs in DAVDroid? I am mostly interested in the following posted expression, as I would like to access my birthday calendar via ICS (read only), but could only find the direct link to the calendar, where you always need to log in:
HTTP REQUEST: PUT /remote.php/caldav/calendars/MichaDO/contact_birthdays/431f1fde-fd75-4b8c-8ba9-0854a31dd49b.ics If-Match: “b24b014ac8d13a5c8a3b128eb95ae215”

So I am missing the access 431f1fde-fd75-4b8c-8ba9-0854a31dd49b for my birthday calendar

Regards … Max