<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
    <title>Colas.Nahaboo.net - fastmail</title>
    <subtitle>Colas Nahaboo personal site, with discussions about programming code, web and computing topics, surfing and SUPing, and various musings.</subtitle>
    <link rel="self" type="application/atom+xml" href="https://colas.nahaboo.net/tags/fastmail/atom.xml"/>
    <link rel="alternate" type="text/html" href="https://colas.nahaboo.net"/>
    <generator uri="https://www.getzola.org/">Zola</generator>
    <updated>2026-08-02T00:00:00+00:00</updated>
    <id>https://colas.nahaboo.net/tags/fastmail/atom.xml</id>
    <entry xml:lang="en">
        <title>gmail-to-fastmail: keep your Gmail labels in sync on Fastmail</title>
        <published>2026-08-02T00:00:00+00:00</published>
        <updated>2026-08-02T00:00:00+00:00</updated>
        
        <author>
          <name>
            
              Unknown
            
          </name>
        </author>
        
        <link rel="alternate" type="text/html" href="https://colas.nahaboo.net/code/gmail-to-fastmail-sync-yourlabels/"/>
        <id>https://colas.nahaboo.net/code/gmail-to-fastmail-sync-yourlabels/</id>
        
        <content type="html" xml:base="https://colas.nahaboo.net/code/gmail-to-fastmail-sync-yourlabels/">&lt;p&gt;&lt;img src=&#x27;gmail-to-fastmail.svg&#x27; align=right width=300&gt;I moved to Fastmail some time ago, but like many of us I kept one foot in Gmail: &lt;a rel=&quot;noopener external&quot; target=&quot;_blank&quot; href=&quot;https:&#x2F;&#x2F;www.fastmail.help&#x2F;hc&#x2F;en-us&#x2F;articles&#x2F;1500000278022-Using-other-email-addresses-with-fetch&quot;&gt;Fastmail&#x27;s &quot;fetch&quot;&lt;&#x2F;a&gt; tool keeps duplicating my incoming Gmail into my Fastmail account — a backup, an escape plan, and a bridge for family members who are not quite ready to leave Gmail yet.&lt;&#x2F;p&gt;
&lt;p&gt;But there was a hole: the &lt;strong&gt;labels&lt;&#x2F;strong&gt; I add on Gmail after the initial migration (manually, or with my rules) were never reproduced on Fastmail. So I wrote &lt;strong&gt;&lt;a rel=&quot;noopener external&quot; target=&quot;_blank&quot; href=&quot;https:&#x2F;&#x2F;github.com&#x2F;ColasNahaboo&#x2F;gmail-to-fastmail&quot;&gt;gmail-to-fastmail&lt;&#x2F;a&gt;&lt;&#x2F;strong&gt;, a single Go binary that incrementally syncs your Gmail labels to Fastmail.&lt;&#x2F;p&gt;
&lt;h2 id=&quot;how-it-works&quot;&gt;How it works&lt;a class=&quot;zola-anchor&quot; href=&quot;#how-it-works&quot; aria-label=&quot;Anchor link for: how-it-works&quot;&gt;🔗&lt;&#x2F;a&gt;&lt;&#x2F;h2&gt;
&lt;p&gt;It reads your Gmail via IMAP (read-only, &lt;code&gt;X-GM-LABELS&lt;&#x2F;code&gt;), and applies the labels on Fastmail via JMAP (a more efficient variant of IMAP), in batches of 10 000. Progress is kept in a local SQLite database, so each run resumes where the last one stopped — once caught up, a run takes about 15 seconds. Perfect for cron.&lt;&#x2F;p&gt;
&lt;h2 id=&quot;what-it-does&quot;&gt;What it does&lt;a class=&quot;zola-anchor&quot; href=&quot;#what-it-does&quot; aria-label=&quot;Anchor link for: what-it-does&quot;&gt;🔗&lt;&#x2F;a&gt;&lt;&#x2F;h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Labels mapped&lt;&#x2F;strong&gt;: your Gmail labels become Fastmail labels, created on demand, never deleted.&lt;&#x2F;li&gt;
&lt;li&gt;&lt;strong&gt;Categories&lt;&#x2F;strong&gt;: Gmail&#x27;s system categories (Inbox, Updates, Social...) become underscore-prefixed labels &lt;code&gt;_Inbox&lt;&#x2F;code&gt;, &lt;code&gt;_Updates&lt;&#x2F;code&gt;, &lt;code&gt;_Social&lt;&#x2F;code&gt;...&lt;&#x2F;li&gt;
&lt;li&gt;&lt;strong&gt;Trash&lt;&#x2F;strong&gt;: emails deleted on Gmail are not deleted on Fastmail, just labelled &lt;code&gt;_Trash&lt;&#x2F;code&gt; — a backup of your deleted mail, with an easy way to &quot;empty the bin&quot;.&lt;&#x2F;li&gt;
&lt;li&gt;&lt;strong&gt;Local cache&lt;&#x2F;strong&gt;: unchanged emails are skipped, so Fastmail&#x27;s API is left in peace.&lt;&#x2F;li&gt;
&lt;li&gt;&lt;strong&gt;Mirror mode&lt;&#x2F;strong&gt;: &lt;code&gt;-m&lt;&#x2F;code&gt;&#x2F;&lt;code&gt;-M&lt;&#x2F;code&gt; optionally imports emails missing on Fastmail, not just labels. There are more options, detailed on the GitGub repository.&lt;&#x2F;li&gt;
&lt;&#x2F;ul&gt;
&lt;h2 id=&quot;installation-usage-and-more-info&quot;&gt;Installation, Usage, and more info&lt;a class=&quot;zola-anchor&quot; href=&quot;#installation-usage-and-more-info&quot; aria-label=&quot;Anchor link for: installation-usage-and-more-info&quot;&gt;🔗&lt;&#x2F;a&gt;&lt;&#x2F;h2&gt;
&lt;p&gt;See the &lt;a rel=&quot;noopener external&quot; target=&quot;_blank&quot; href=&quot;https:&#x2F;&#x2F;github.com&#x2F;ColasNahaboo&#x2F;gmail-to-fastmail&quot;&gt;GitHub repository&lt;&#x2F;a&gt;.&lt;&#x2F;p&gt;
&lt;h2 id=&quot;why-go&quot;&gt;Why Go?&lt;a class=&quot;zola-anchor&quot; href=&quot;#why-go&quot; aria-label=&quot;Anchor link for: why-go&quot;&gt;🔗&lt;&#x2F;a&gt;&lt;&#x2F;h2&gt;
&lt;p&gt;Because it is a single self-contained binary with no runtime dependencies — you know my &lt;a href=&quot;&#x2F;blog&#x2F;go-single-binary-fanatic&quot;&gt;thing about that&lt;&#x2F;a&gt;. No Python env, no node_modules, no nothing. Free (MIT).&lt;&#x2F;p&gt;
&lt;p&gt;Also, AI co-written: don&#x27;t like, don&#x27;t use.&lt;&#x2F;p&gt;
</content>
        
    </entry>
</feed>
