Not Equal Sign (≠)

The not equal sign ≠ is Unicode U+2260, meaning “is not equal to”. Press Copy to put it on your clipboard, or type it with Option + = on a Mac.

Unicode
U+2260
HTML
≠
Word
2260 Alt+X
Mac
Option + =

How to type the not equal sign (≠)

The quickest way is to press Copy above and paste. To type ≠ yourself, use the method for your device below. On a Mac it is Option + =.

Windows

  1. In Word or Outlook, type 2260 and press Alt + X. Alt + X converts the hex code before the cursor into the character, and back again.
  2. Press Win + R, type charmap and press Enter. Tick “Advanced view”, search for Not Equal to, then Select and Copy. Character Map is built into every version of Windows.

Not equal sign on Windows

Mac

  1. Press Option+=. On the standard US and US-International layouts.
  2. Press Control + Command + Space to open the Character Viewer, search for not equal and double-click it.

Not equal sign on Mac

Linux & ChromeOS

  1. Press Ctrl + Shift + U, type 2260, then press Enter or Space. Works in GTK and IBus apps (GNOME, Firefox, Chrome, LibreOffice) and on ChromeOS.
  2. Press your Compose key, then = /. Needs a Compose key set in your keyboard settings.

iPhone & iPad

  1. Tap 123, then #+=, then touch and hold = and slide to ≠.
  2. Copy ≠ from this page, then go to Settings → General → Keyboard → Text Replacement and add it with a shortcut such as ;not. The shortcut then turns into the symbol as you type, in every app.

Not equal sign on iPhone

Android

  1. Copy ≠ here, then open Gboard settings → Dictionary → Personal dictionary and add it with a shortcut.

Not equal sign on Android

Microsoft Word

  1. Type 2260, then press Alt + X.
  2. Insert → Symbol → More Symbols. Set “from” to Unicode (hex), type 2260 in “Character code” and click Insert.
  3. On a Mac, Option+= works in Word too.

Google Docs

  1. Type != followed by a space; Google Docs substitutes ≠ automatically.
  2. Insert → Special characters, then search for “not equal” or draw it in the box.

Excel & Google Sheets

  1. Enter =UNICHAR(8800) in a cell. It works in Excel 2013 and later and in Google Sheets.

HTML

  1. Write ≠ or ≠ in your HTML.

What does ≠ mean?

≠ states that two values are different: 3 + 3 ≠ 7. It is an equals sign struck through, and it is usually credited to Leonhard Euler. Like = it takes a space on each side.

Programming languages cannot rely on the symbol, so they spell it out: != in C, JavaScript, Python and most others, <> in SQL, Visual Basic and Excel, and ~= in Lua and MATLAB. Some coding fonts draw != as a ligature that looks like ≠, but the file still contains two characters. Typing the real ≠ into code will cause a syntax error in most languages.

≠ only says the values differ; it does not say which is larger. For that you need <, >, ≤ or ≥.

Common uses

  • Algebra and proofs: x ≠ 0 (so we may divide by x)
  • Logic and set theory: a ≠ b
  • Plain-text notes: “cost ≠ value”

Not Equal Sign codes for HTML, CSS and programming

Every code below produces ≠. Use the HTML entity in web pages, the CSS escape in content, and the escape sequence in source code.

Codes for ≠
Unicode code pointU+2260
HTML entity (named)&ne;
HTML decimal&#8800;
HTML hex&#x2260;
CSS contentcontent: "\2260";
JavaScript"\u2260"
Python"\u2260"
Python (by name)"\N{NOT EQUAL TO}"
Java / C#"\u2260"
LaTeX\neq
UTF-8 bytesE2 89 A0
UTF-162260
URL encoded%E2%89%A0
Mac shortcutOption + =

≠ vs look-alike characters

These characters look similar to ≠ but have a different meaning and code. Pasting the wrong one can break search, sorting and screen readers.

CharNameWhen to use it
Not Identical to
U+2262
Not identical to. The negated form of ≡, used for congruence and identity.
Not Almost Equal to
U+2249
Not almost equal to, the negated ≈.
Equals
U+003D
Equals sign. The ≠ sign is its negation; in formulas type <> (Excel) or != (code) instead of ≠.

Symbols similar to ≠

Click to copy, or open a symbol for its codes. See the full math symbols collection.

≠ character properties

Official Unicode name
NOT EQUAL TO
Also known as
not equal to, does not equal, unequal sign, not equals symbol
Code point
U+2260
Unicode block
Mathematical Operators (U+2200–U+22FF)
General category
Math symbol (Sm)
Added in
Unicode 1.1 (1993)
Plane
Basic Multilingual Plane (0)
Emoji
No, it is a text symbol

Frequently asked questions

How do I write “not equal” in Excel?

Use <> in formulas, for example =IF(A1<>B1,"different","same"). The ≠ character is only text in Excel.

What is the not equal sign in Python or JavaScript?

Both use !=. JavaScript also has !== for strict inequality, which also compares the type.

Is there an alt code for the not equal sign?

No. ≠ is outside the Windows-1252 and code page 437 character sets, so no Alt + number code produces it. Copy it from this page, type 2260 then Alt + X in Word, or find it in Character Map.

How do I type the not equal sign on a Mac?

Press Option + =. It works in every app on the US keyboard layout. You can also open the Character Viewer with Control + Command + Space and search for it.

What is the HTML code for the not equal sign?

Use the named entity ≠ or the numeric reference ≠ (hex ≠). All three display ≠ in every browser.

What is the Unicode for the not equal sign?

≠ is U+2260, officially named NOT EQUAL TO, in the Mathematical Operators block. It has been part of Unicode since version 1.1 (1993).