After clearing the browser cache and restarting
Gmail, you should see the
collapsible TeX for Gmail menu in the Gmail
Navigation Bar on the left.
(If you used the alternative installation, you need to click on the
newly created Gmail bookmarklet first.)
The menu should have the following items:

- rich math (F8)
- simple math (F9)
- auto:
**off** 1 2 4 8, **rich** / simple
- help & about

### Reading email

When you receive an email containing LaTeX-encoded math, hit the
link **simple math** or **rich math**, or press **F9**,
resp. **F8**. LaTeX in your emails will be transformed into something
more readable (only temporarily, until you close the message).

For **rich math** to work, LaTeX must be properly enclosed in
$...$ or $$...$$. For **simple math**, it does not have to be: the
program will guess which part is math, and which part is not.

The **simple math** method only supports a subset of LaTeX (subscripts,
superscripts, greek letters, \sqrt, \sum, \prod, \cap, \cup, etc.)
and may not work on every input (after all, it is guessing). But it
is useful when you receive an email with pseudo-LaTeX which is not
enclosed in proper delimiters.

### Sending email

When composing an email, make sure you are NOT in
"Plain text mode"!

The easiest is to compose an email in **Rich format**. Hitting
the link or **rich math** or pressing F8 will transform your
LaTeX into images with equations.
**To turn an image back into LaTeX,** do the following: click on
the image and then choose OK in the popup box.

Hitting the link **simple math** or pressing F9 will transform
your LaTeX into simple HTML with subscripts, superscripts, greek
letters etc.
Ctrl-Z works for "undo".

Exactly the same as for reading,
for **rich math** to work, LaTeX must be properly enclosed in
$...$ or $$...$$.
(In $...$ the first character after $ and the last
character before $ must not be blank spaces. This way, you can
still write something like $100 and $200, and TeX for Gmail will
understand that you talk about money, not math.)

For **simple math**, math expressions do not have to be property
enclosed; the program will guess which part is math, and which part
is not.

\mathbb{A}, \mathcal{A}, \mathfrak{A} produce correct Unicode
characters.
Warning: Mobile phones and some older
browsers may lack fonts to display these Unicode characters,
so it may be wise to stick to \dA = \mathbf{A}, etc.
iOS devices seem to correctly display \mathbb{CHNPQRZ},
\mathcal{BEFHILMRego}, \mathfrak{CHIRZ}. Android phones seem to only
manage \mathcal{M} and \mathfrak{IR}.

All LaTeX commands available in Simple Math Mode are listed
here.

Occasionally, after hitting F9 you may have trouble exiting out of
subscript or superscript mode, or the font used to typeset
mathematics. If it happens, use "Remove Formatting" from Gmail HTML
editor's toolbar.

Whichever method you use, your addressee does not
need to have TeX for Gmail installed. The math should be directly
viewable in most browsers, including mobile browsers.

Here are some things to consider when choosing between HTML or
images in the outgoing emails:

**simple math** is just standard HTML, which any browser or email
client can read, online or offline.
**rich math** means links to images hosted by CodeCogs on
their server, and used in this app with their explicit
permission. The images are not available offline, unless they have
been cached by your computer.
- If a server goes down or the service is discontinued (as
Google's LaTeX engine is going to do soon), the images will
no longer render.
- The server at CodeCogs has a
daily fair usage
limit, currently 3,000 equations (per IP address?)

Note:

- Color works with F8. Try writing $\color{Red}{\mathbb C^n}$
and pressing F8 to get .
Other available colors: Blue, Green, Yellow, Pink, Orange,
Purple, Maroon, Teal.
- TeX accents work with F9. Try writing H\'el\`ene and pressing
F9 to get Hélène.

### auto: **off** 1 2 4 8, **rich** / simple

Turning this on produces the following effect. When composing a
message, math expressions properly enclosed in $...$, $$...$$,
\(...\), or \[...\] will be automatically typeset. If the rich mode
is chosen, they will be replaced by (links to) images. If the simple
mode is chosen, they will be replaced by simple HTML.

Thus, this is roughly equivalent to pressing F8 or F9 every 1, 2, 4,
or 8 seconds. But not quite. When you press F9, the whole text of
the message is transformed, including math expressions and TeX
accents not properly enclosed in $...$, etc. In the auto mode, only
the expressions in $...$ etc. are affected.

A side note is that in the auto mode, when the simple mode is
chosen, TeX for Gmail adds a blank space at the end of the
formula. Otherwise, Gmail frequently gets stuck in the subscript or
superscript mode. Once you know about this, with a little practice
this should not be an inconvenience.

Novice LaTeX users may also find CodeCogs'
Online LaTeX
Equation Editor useful. The link is available at the bottom of
TeX for Gmail's window. You can compose your formula there and then paste
it in the Compose window.

### Support for theorem-like environments

Writing

\begin{theorem}The equation $$x^n+y^n=z^n$$ has no solutions in positive integers x,y,z,n with $n\ge3$. \end{theorem}

produces

**Theorem. **The equation

x^{n}+y^{n}=z^{n}

has no solutions in positive integers x,y,z,n with

n≥3.

Note that '\begin{theorem}...\end{theorem}' should

**not** be enclosed in
$$...$$. On the other hand, the usual math environments such as matrix,
pmatrix, bmatrix, still work as before in Rich Math mode if they are
properly enclosed in $$...$$.

There is an optional argument for the theme: red, blue, green,
gray, yellow (default). For example,
writing

\begin{theorem}{green}The equation $$x^n+y^n=z^n$$ has no solutions in positive integers x,y,z,n with $n\ge3$. \end{theorem}

gives

**Theorem. **The equation

x^{n}+y^{n}=z^{n}

has no solutions in positive integers x,y,z,n with

n≥3.

The optional argument can also be used to add
any legal

CSS. In
particular, for the color names you can use something like

#FFFFF0
or rgb(248,248,248), or

named
colors. See also

this
page for a large database of colors. For example,

\begin{theorem}{background: pink; border: 2px solid crimson;
font-family: 'Times New Roman'; font-size: 120%; border-radius:2ex}The equation $x^n+y^n=z^n$
has no solutions in positive integers x,y,z,n with $n\ge3$.
\end{theorem}

gives

**Theorem. **The equation

x^{n}+y^{n}=z^{n}

has no solutions in positive integers x,y,z,n with n≥3.
For a box without a title, use
'\begin{} ... \end{}'. Works both in Simple and Rich
modes.

If you need to insert a line break inside an environment, **do
not** press ENTER, since it performs a complicated function in
Gmail Compose Box, with various side
effects. Press **SHIFT-ENTER** (in Chrome) or **CTRL-ENTER**
(in Safari) instead. There must be an equivalent in Firefox but I
haven't figured it out.
If things go wrong, you can use Gmail Undo
(control-Z).

### More formatting options

In addition, the main function of the **Simple Math mode** is to make
any expression in $...$ into an HTML span. As a byproduct, most
HTML constructions inside $...$ produce correctly-formatted HTML, e.g.

$<b>Bold</b>, $<i>Italic</i>, <del>Strike-through</del>$

give

**Bold**,

*Italic*,

~~Strike-through~~
when Simple Math mode is used.
$<h2>Headers</h2>$ work, too. Also, $----$ (four or more)
gives a horizontal line, $--$ gives an n-dash –, and $---$ an
em-dash —. And of course TeX accents work, too: $H\'el\`ene$
gives Hélène.

### Using LaTeX with Chat

Just include your math in $...$ or $$...$$. It should automatically
show upon entering.