iOS AutoSync - what's the status?

It looks like every comment on this subject has been closed. How is it so, so difficult to Auto Sync for Anki when literally any other app I have autosyncs? I feel like it’s such a crucial feature. The number of times I haven’t autosynced and started the deck elsewhere and lost progress is innumerable.

This very, very basic feature would be a game changer in terms of user experience. I don’t understand how this is not a priority? Especially for an app that’s a paid app, I really hope this can be addressed.

2 Likes

Anki syncing is long, so maybe Apple will interrupt it.
Instead, it is possible if you customize Apple’s shortcut to show a notification to sync when you close and open Anki.(Well, it’s a bit complicated.)

1.Apple Shortcuts
2.Automation
3.Tap Plus icon
4.Create Personal Automation

5.App
6.App → Anki
7.is Opened[ON] is Closed[ON]
8.Next

9.Add Action
10.Searh [Show Notification]
11.Input text [ anki://x-callback-url/sync ]
12.Tap the arrow icon beside the text
13.PlaySound[OFF]
14.Next

15.Ask Before Running[OFF]
16.Done

Tap the notification and then tap the URL scheme to synchronize.
If you encounter any problems, restart your iPhone and turn off automation.

2 Likes

Unfortunately, it is not easy to address. iOS doesn’t have a concept of closing and opening an app like computer OSes do, and iOS won’t let the app run for more than 30 seconds when you switch away from it. Syncing in the background while the app is in the foreground would be one solution, but that requires major changes to the current sync protocol and study screen, and it’s not something I’ve had time to look into yet I’m afraid.

While not a solution, if you were not already aware, the color of the sync button changes when a sync is pending.

2 Likes

Is there any update on this topic? It looks like it’s the most frequently asked feature (and in the only paid version of the app!) yet completely neglected by the author. I saw the rationalization of “iOS doesn’t have a concept of closing and opening” in a thread a few years ago. Is there any new, real timeline when this feature will be added?

If not, please advise how to get a refund.

1 Like

Probably no major updates at the moment. For AnkiMobile refunds you need to contact the Apple store, not the official Anki. Personally I think it would be useful to create a shortcut on the iphone and sync it every day at a certain time with automation, the mobile decks work as a backup. Last year I used a shortcut to sync when I opened and closed Anki, but this was not very useful, because it is inconvenient to unnecessarily sync when I frequently close and open websites to edit cards. Maybe a more advanced shortcut using variables might be useful, but it has not been tried yet.

1 Like

That’s upto Apple.

1 Like

Apple apps have relatively little development freedom but this is one of the advantages of Apple devices. The inability to run apps in the background means that malicious app developers cannot easily run viruses or malware in the background. Apple has introduced various regulations for such security. e.g. Apple’s apps are stringently screened and passwords are difficult to crack, so the security of Apple devices tends to be relatively high.

Some users value security over low price and functionality and if a user’s smartphone or laptop stores important info such as work customer info or confidential info, or if the user is a wealthy individual who is an easy target for fraud. Apple is an easy and safe choice. That’s one reason why Apple is still so popular, so far Apple has more than a majority of smartphones in the high price range.

1 Like

So, for an update to this:

For AnkiMobile:

The only way to auto-sync is to set up a custom IOS Shortcut to trigger ‘Open URL’ for ‘anki://x-callback-url/sync’, which will trigger Anki to open again and sync.

Then, put an action in the shortcut to ‘Go to Home Screen’ and an automation to run your shortcut when you close Anki.

The problem will be that you will be stuck in a loop. (Anki closes → Trigger Shortcut → Anki opens/syncs → Anki closes → Repeat).

To counter this, you need to set up another shortcut that checks the last time your shortcut ran and runs it only if a specific time has passed:

The best I have found is ‘Last Time Run’ from ibanks (He has a video tutorial step-by-step on the website).

Summary:

  1. Create an Anki Shortcut to Sync and Close
  2. Create ‘Last Time Run’ and connect it to the above shortcut.

So each time you close Anki, it will open again, sync, and then close. It will have a timeout until it runs again, countering the loop.

I know this is complicated, but it’s the only way around currently. Hope I helped! :slight_smile:

3 Likes

Just tried it works perfectly. do you have any other similar useful tips around using anki or automations?

Lately the feature I’ve been using a lot is the timer to auto open Anki. Push the Home button to start a 10 minute timer, when it finishes Anki will auto display. (e.g. review with anki → break → review with anki → break → loop)

like this:

iOS Shortcuts

  1. Show notification Break 10 min
  2. Wait 600 seconds
  3. Open Anki

Share button → Add to Home Screen

the downside is that the shortcut stops and doesn’t run when you close the iPhone or go to the lock screen, so it’s probably necessary to keep the iPhone open.

1 Like

Hi I got a question I got the first shortcut running, but I don‘t get the second one and also the frist seems to do nothing expect show me the notification of anki://x-callback-url/sync. Can you please help me this would mean the world to me

could you please help me how I can also figure it out on my ipad and iphone