AndroidApps

Quick Tasker tip: Use K-9 Mail to get email info into Tasker

Screenshot_2013-06-22-05-16-17Tasker has built-in features for gaining access to information from text messages and the phone, but email is a bit more elusive. Part of the reason is that there are a lot of email clients out there, and Tasker support isn’t exactly high up on the list of many of them. There is however one that has Tasker support: K-9 Mail.

First off, I should mention that this requires you to use the K9 Mail client, and many might not want to do that just to gain access to emails in Tasker. I personally tried it and couldn’t live with the trade off, but I also didn’t try to just have K-9 run in the background as a secondary email system, so that might be an option. There are some client-specific methods out there, but since they’re far from beginner level.

K9 Mail is one of a handful of apps that are natively supported by Tasker as third party apps. This means that they essentially have a Tasker plug-in component, but one that is built into Tasker and simply unlocks when you install the app, rather than one that apps a plug-in using Tasker’s plug-in system. In practice, this means that you’ll find options relating to them in the 3rd Party categories, not the Plugin categories. For K-9 Mail, there’s a context for receiving an email in K-9 in the Event section, allowing you to have tasks run when you get an email.

As for getting access to the information in emails, that’s done via some built-in variables. This is described in the Tasker user guide:

Email From / Cc / Subject / Date / Time (dynamic)
%EFROM / %ECC / %ESUBJ / %EDATE / %ETIME
The From, Cc, Subject, Received Date and Received Time of the last email received by the K9 email agent.

What this means is that if you use K-9 Mail, those variables will be populated with the respective information, automatically- just like for SMS.

Like I said, this is essentially the simple method of getting emails into Tasker, and requires you to use a specific email client. Whether or not that switch is worth it to you is a decision you have to make for yourself, but at least the option is there.

tasker banner - for some reason we don't have an alt tag here

Pocketables does not accept targeted advertising, phony guest posts, paid reviews, etc. Help us keep this way with support on Patreon!
Become a patron at Patreon!

Andreas Ødegård

Andreas Ødegård is more interested in aftermarket (and user created) software and hardware than chasing the latest gadgets. His day job as a teacher keeps him interested in education tech and takes up most of his time.

Avatar of Andreas Ødegård

5 thoughts on “Quick Tasker tip: Use K-9 Mail to get email info into Tasker

  • From what I understand, Kaiten Mail is the successor to K9 written by some of the same developers. I didn’t try, but I’d guess it has the same functionality discussed here, but it’s more modern and still gets updates.

    Reply
  • Aqua mail says in their play store description that it supports tasker integration. It looks pretty neat with gmail app like features and look and as a dark theme to save battery life on AMOLED screens. It also has a pretty high user ratting (4.4). I’m installing it now on my devices.

    Reply
  • I’m rooted and use scripts to access Sender Name, Email, and Subject from Gmail. Works pretty good, and I don’t have to use a different email client in the background. It’s a bit round-about as it actually accesses and parses the Gmail database.

    Reply
  • I would just like to say that having a second mail app for tasker works completely fine and there is absolutely nothing wrong with it… :)

    Reply
  • Avatar of maximilien

    Hi, could you please tell me if you have found a way to automatically archive an email based on some context (eg. Message content or sender)?
    Thanks.

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *