High mobile data usage

I’ve had your app for a few years and noticed that it’s usage of mobile data seems high even when on wi-fi. This issue was most pronounced while on a shelter in-place order and working from home, where my connectivity was almost exclusively on wi-fi. Even with those conditions, the mobile data usage was almost 200mb over a 10 day period. (I’m on an Android that shows the mobile data usage for EVERY app installed on it)
Given the conditions I mentioned, it seems the mobile data usage (which isn’t unlimited on my plan) should be minimal (and it’s minimal with other clients under the same conditions). As I stated previously, I’ve had the app for a few years, so I’ve gone through the settings to find any place I can adjust this usage, but came up with nothing. This caused me to uninstall K9, but I would like to be able to use the app again because it did everything that I wanted.

There are a number of settings you can adjust to reduce data usage. Setting the “Local folder size” lower will reduce the number of messages checked / retrieved with every poll. The “Sync messages from” setting can also limit the refreshing of older emails. The “folder poll frequency” can be set to a longer period to reduce the number of polls. And the “Fetch messages up to” setting can be used to prevent the automatic downloading of large emails (they can later be fully downloaded within the message screen).

The “Poll when connecting for push” setting can be turned off to prevent extra polls (at the risk of possibly missing messages until the next scheduled poll). The number of folders that have push enabled can be reduced to cut the number of IDLE connections. And the “Refresh IDLE connection” setting should be set to as long of a duration as your networks will allow (some firewalls / routers aggressively cull idle connections, but others don’t).

1 Like

You replied with 5 suggestions for reducing data usage…which is appreciated, but I think there is a larger, more fundamental question that should be addressed:
Why is mobile data the ONLY choice for these features?
I have the ability to turn of mobile data on my phone. Just a cursory glance at your suggestions implies that if I turned off mobile data on my phone, the app would be dead in the water.

I’m not sure I understand your question. Standard android will switch all data usage to wifi if it is connected and can see the internet. Apps don’t really have any control over this, it happens automatically. If you’re on wifi, all data usage should happen over the wifi connection.

Well, actually K9 doesn’t automatically use it. Here are the results of an experiment I did:
Setup: I installed K9 side by side with another email app.

  • Both apps are connected to the same email account (Yahoo) on the same mobile device.
  • Each app is only showing the Inbox and 3 filtered folders. These were the only folders required by me, the user.

This is to establish a baseline of each app using the same device, same wi-fi, same account and same amount of email.
Findings:

  1. K9’s mobile data use was 6.42 MB for background processing and 0 B for foreground processing in a 24-hour period while the other app’s mobile data use was 190 KB background processing and 0 B for foreground processing in a 10 day period.
    Fortunately, I have the ability on my device to disable the mobile data usage per app, so I disabled it for K9 after that enormous, first 24-hour usage. The other app has not had the mobile data usage disabled. This should be the biggest takeaway from this post. For whatever reason, K9 is a data hog in background processing and will primarily use mobile data to do it unless explicitly told to stop.
    Additionally, I followed the suggestions provided in a previous post:
  • “Local folder size” is set to 10 messages
  • “Sync messages from” is set to the last month.
  • “folder poll frequency” is set to every minute.
  • “Fetch messages up to” is set to 32 kb
  • “Poll when connecting for push” is disabled
  • “Refresh IDLE connection” is set to every 24 minutes
  1. Both apps have push notification enabled. Unfortunately, this was not enough to receive notifications from the filtered folders on either app. K9 had the advantage here because of the Poll feature. This provided the notifications for new email arriving in the filtered folders. The other app seems to lack a Poll feature (or at least one that was configurable). The other app did send notifications from the filtered folders for about 5 days then suddenly stopped.

  2. Even though push notification was setup for the inbox, notifications stopped for the inbox when I turned off polling for the inbox. It seems both have to be turned on for the Inbox to function properly.

K-9 does not choose to use mobile data. It only uses the system provided network connection, as @zootboy already mentioned. A reason for the behavior you are experiencing could be that Android switches off WiFi when the device is idle for a long time because WiFi needs more battery than mobile networks. There is a setting Keep wifi on Sleep that should be set to Always .

Once per minute is an extremely high poll frequency. That would execute over 1400 polls in your 24-hour test period. If each poll transferred just 4 kB of data, that would easily hit 6 MB per day. If you’re using TLS, the encryption overhead alone can easily hit 4 kB.

I would focus on trying to get IDLE working if you’re very sensitive to data usage. Depending on your version of android, there are a nunber of spots you may need to tweak settings in order to allow K-9 to keep IDLE connections alive.

First thing: Keep wifi on Sleep was removed in Android 9. The default is Always.
Second thing: If I’m polling every minute, when would the connection have a chance to be Idle anyway?
Thirdly: I think there may be an arrogance about this application that may prevent an examination of it in regards to issues brought up by actual users. I imagine that a support forum should be somewhere that a user can report an issue that may have been missed by developers and testers and not have the focus be about how the user is doing something wrong. As evidence to support my assertion is the another issue that was stated in my last post that went unnoticed in the responses: Push is only working in INBOX if I have polling set for it.

I am sorry that it sounded this way. I am not a native English speaker. If anything sounded rude, it was not on purpose.

We are currently just guessing things that might cause the issue. At this moment, it is pretty much impossible to fix the problem because we do not know what causes it. The goal is to find out what is different on your device than on ours. If we find out what is different, we can reproduce it on our own devices and go bug hunting.

How do you know that push (also called imap idle) is working and that the message is not just loaded by polling every minute? Maybe push is just broken (this is actually not too unlikely. Many users have that problem in the current stable version when using a current Android version).

Each folder is configurable, so I turned off poll for the inbox and left push on. As I mentioned in my post, I am still running another email app concurrently. That app continued to receive email, but K9 stopped receiving those same emails after poll was turned off. But, if the issue is Andoroid 9, then basically K9 will only work with poll activated (which contributes to the data hog situation). But, as a practical matter, polling intervals can’t be reduced too much because then important/timely emails will be missed.

I’ve had that problem for ages, but I never had to set Poll to every minute. I had it set to run every 12 hours and set that idle timeout thingy to 24 minutes.

With those settings Push has always worked and I never missed a mail on P or Q like that, across several devices :slight_smile: