I have an equation like this:

      P(A \cup B) = \sum_{\omega \in A \cup B} P(\omega) = \sum_{\omega \in A} P(\omega) + \sum_{\omega \in B} P(\omega)
      = P(A) + P(B)

For some reason, LaTeX is automatically labeling the equation. How do I turn that off? Secondly how do I write something in LaTeX on this site. I tried enclosing in '$' but it doesn't work.


8 Answers 8


Do a \begin{align*} ... \end{align*}. That should do the trick.

  • 52
    The "*" versions of the equation environments suppress numbers. This is true for align, but also for AMS environments equation, gather, multline, and flalign. Commented Sep 1, 2010 at 20:17
  • 12
    On a side note, one needs to include {amsmath} package by \usepackage{amsmath} for * environments
    – Nishant
    Commented Nov 12, 2015 at 19:48
  • 5
    Is there a setting to disable equation numbers for the whole document? Commented Apr 8, 2018 at 2:41

If you only want some of the lines in an align environment to not be numbered, just put \nonumber before the end characters on each of the lines you don't want to have numbers. Otherwise, use align* as JCL suggested so that none of the lines will be numbered.

  • 8
    I think you mean \notag.
    – TH.
    Commented Sep 15, 2010 at 10:57
  • 1
    I've never used \notag, but perhaps that works also.
    – Rebekah
    Commented Sep 15, 2010 at 11:37
  • 1
    I think this is to be preferred; it's the way intended by Latex. Commented May 12, 2015 at 0:02
  • @YanKingYin which is preferred?
    – minseong
    Commented Sep 20, 2017 at 15:21
  • 2
    I meant \nonumber, but I'm not an expert in Latex and I forgot why I wrote that comment... Anyway I find \nonumber works fine. Commented Sep 21, 2017 at 2:08

As a sidenote, the mathtools package, which makes some improvements on amsmath, provides a way of labeling only those equations that are referenced in the text.

enter image description here

  a = b \label{eq1} \\  
  c = d \label{eq2}  
Some text, \eqref{eq2}.  

In this case, only the second of the equations, c = d, is numbered, as that is the only one being referenced in the text.


  • three compiler passes are required for the references to show up properly
  • this does not work with cleveref, but the cleveref manual mentions another package, autonum, that performs the same task, yet is compatible with cleveref.
  • the manual of the present version (dated 2012/05/10) notes two bugs, one can cause that the number is printed close to, or on top of, the equation, the other relates to ntheorem. Refer to the manual for details.

If you use this:


try this instead:


This solution requires the use of the package amsmath.


Note whilst the above answers are relevant to the question, a lot of people include equations in LaTeX using the \begin{equation} which works without explicitly including the amsmath package in a LaTeX document. However when one attempts to the use \begin{equation*} directive (to omit numbering) an error is generated. Thus in this case it should be pointed out that one needs to explicitly import the amsmath package:

  • 2
    This answer deserves more atention
    – Educorreia
    Commented May 20, 2020 at 23:06

"\nonumber" sometimes does not work for me. Another possibility is to do:

$ P(A \cup B) = \sum_{\omega \in A \cup B} P(\omega) = \sum_{\omega \in A}
P(\omega) + \sum_{\omega \in B} P(\omega) = P(A) + P(B) $
  • 2
    Please be a bit more specific about the circumstances when "\nonumber ... doesn't work for me". You should probably insert a \displaymath directive immediately after the opening $ symbol so that the \sum symbols will be set in "large" mode, as this is the generally expected behavior for displayed equation. A downside to your proposed method is that the vertical spacing above and below a center environment is not likely to be the same as for displayed equations.
    – Mico
    Commented Jan 4, 2014 at 21:10
  • 3
    I would strongly advise against this method, as math typeset in text-mode (ie. using $) and set in display-mode (ie. using a dedicated environment) have quite different spacing to the text above and below. On top of that, certain characters are typeset differently, as @Mico mentions, and even though \displaymath takes care of this, the spacing will remain wrong. Commented Mar 5, 2014 at 7:21
  Solve these problems
  1. \;\; &   x= y+z & 2.\;\; &x^n= y^n+z^n \\  
   3.\;\; &  x= y+z &  4.\;\;  & x^n= y^n+z^n \\ 

    {\bf  This is some sample text we will use to create a somewhat longer text
        spanning a few lines.}

   5.\;\; &  x= y+z & 6.\;\; & x^n= y^n+z^n\\   

This gives required output.

  • 4
    Levesque already suggested align* in his answer. Commented Oct 27, 2016 at 15:31
  • It's not a good idea to have only one line in any display environment except equation/equation* or \[ ... \]. It's also not a good idea to end a display with \\ . Commented May 8 at 14:59

You can just delimit your equation with \[...\] and it will have no numbers. For example

  Equation here

and the equation will have no number.

  • Although if OP truly used align (with & and \\ ), then changing to \[...\] will cause many errors to crop up.
    – Teepeemm
    Commented May 8 at 16:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .