LaTeX Anywhere Install
Chrome extension · Manifest V3 · free and open source

LaTeX snippets for every editor on the web.

Type ;a for \alpha, x/ for \frac{x}{} and Tab through the fields, in Overleaf, ChatGPT, Claude, Notion, HackMD or any text field. The snippets are the ones from Emacs laas and cdlatex, ported one-to-one.

main.tex — any editor

    
Renders as
218laas.el snippets, ported entry by entry
296cdlatex symbols, modifiers and Tab commands
6kinds of editor: CodeMirror 5 & 6, ProseMirror, contenteditable, textarea, input
0bytes of your text sent anywhere
Features

Write math as fast as you think it.

Every animation below is recorded keystroke by keystroke from the real engine: nothing is mocked up.

01

laas snippets, auto-expanding

Inside math, short keys expand the moment you type them: ;a → \alpha, sr → ^2, <= → \leq, x1 → x_1, iff → \iff. Outside math nothing happens, so ordinary writing is never touched.

Press Backspace right after an expansion to get back what you typed.

notes — any text field

    
Renders as
02

Fractions that take what's to their left

/ turns the object before it into a numerator: x_1/ → \frac{x_1}{}, and (a+b)/ drops the parentheses → \frac{a+b}{}. // makes an empty fraction to fill in.

homework — any text field

    
Renders as
03

cdlatex, too

Backtick symbols (`a → \alpha, `` for the second level), quote modifiers on the last character (x'. → \dot{x}, v'b → \mathbf{v}), _ → _{}, Tab commands like frTab and sqTab, and $ [ { pairing.

physics.tex — Overleaf

    
Renders as
04

Tab that knows LaTeX

Snippets have fields, like yasnippet: Tab moves to the next one, and after the last it leaves the snippet. Outside a snippet, Tab moves like cdlatex-tab: out of a group, into the next empty {}, past the closing $. Shift+Tab goes back.

proof.md — HackMD

    
Renders as
05

A live preview while you type

While the caret is in math, a small card renders the whole formula, marks where you are with a caret and shows the fields still to fill as □. It sits above the caret (or below, or in the corner) and Esc hides it.

ChatGPT's message box with formulas rendered in place and a preview card above the formula being typed
In ChatGPT's message box.
06

Formulas rendered in place

Once the caret leaves a formula, it's drawn typeset right over its source, as crisp SVG. Move the caret back in (or click it) and the LaTeX is there to edit. It keeps up with long documents: only the formulas near the window are drawn.

The same message with every formula rendered in place
The same message, with the caret in the text.
Try it

Type here. It's the real thing.

This box runs the same engine, preview card and in-place rendering as the extension. Click into it and try $, ;b, x/, sum, then Tab.

Formulas are rendered while the caret is elsewhere; click one to edit it.
Cheat sheet

Every snippet, one keystroke away.

Press Alt+Shift+K on any page for this table, filtered to what works on that site. Search it by key or by command.

Make it yours

Your own snippets, your sites.

07

Write your own snippets

The options page has a small config language: a JavaScript object with triggers, replacements, fields, regex triggers and per-site rules. Errors are shown as you type, and a test box tries the config before you save it.

// My snippets
{
  snippets: [
    { trigger: "EE", replacement: `\mathbb{E}`, options: "mA" },
    { trigger: /([a-zA-Z])tld/, replacement: `\tilde{[[0]]}`, options: "mA" },
    { trigger: "beg", replacement: `\begin{$1}
	$0
\end{$1}`, options: "tA", sites: ["overleaf.com"] },
  ],
  disabledSites: ["mail.google.com"],
}
08

Per-site control

Turn LaTeX Anywhere off for a site from the toolbar, and choose what mk and dm insert there: $…$ or \(…\) inline; $$, \[ \], equation* or align* for display math.

The toolbar popup: on/off for this site, and what mk and dm insert
Reference

The details.

Works in

  • Overleaf, JupyterLab
    CodeMirror 6
  • HackMD
    CodeMirror 5
  • ChatGPT, Claude
    ProseMirror
  • Notion and other rich editors
    contenteditable
  • Any textarea or text input
    native
  • Input methods such as Zhuyin and Pinyin
    IME

Shortcuts

Alt+Shift+LTurn LaTeX Anywhere on or off
Alt+Shift+KOpen the cheat sheet
Tab / Shift+TabNext / previous field, or move like cdlatex
BackspaceUndo the expansion just made
EscHide the preview card

Install

From the Chrome Web Store

Works in Chrome, Arc, Edge, Brave and other Chromium browsers.

Add to Chrome

From GitHub

Download the zip from the latest release, unzip it, turn on Developer mode in chrome://extensions and choose Load unpacked.

The engine, for your own app

npm install web-laas-engine: the snippet engine and editor adapters, with no extension APIs.

On npm

Privacy & permissions

LaTeX Anywhere runs entirely in your browser. It collects no data, makes no network requests of its own, has no analytics and loads no remote code. Your settings stay in the browser's extension storage. Privacy policy.

PermissionWhy
storageYour settings: on/off, sites you turned it off on, per-site delimiters, preview options and your own snippets.
scriptingLoads the preview and cheat sheet into a page only when they're needed, and brings tabs that were already open up to date after an install or update.
notificationsShortcut feedback on pages where the in-page message can't show, such as chrome:// pages.
Access to all sitesSnippets have to work in whatever editor you write math in, so the content script runs on every site. Nothing on the page leaves your browser.

Know the limits