The tilde ~ and the mathematical tilde operator ∼ can look almost identical. In many fonts, both appear as a short horizontal wave.
They are different Unicode characters. The keyboard tilde is U+007E TILDE. The mathematical character is U+223C TILDE OPERATOR.
The distinction matters because ~ is a general-purpose keyboard character used in computing, plain text, and informal notation, while ∼ is specifically encoded for mathematical use.
Tilde and Tilde Operator at a Glance
| Symbol | Unicode name | Code point | Typical role |
|---|---|---|---|
| ~ | TILDE | U+007E | Keyboard symbol, computing, and plain-text notation |
| ∼ | TILDE OPERATOR | U+223C | Mathematical relation or operator |
These characters are part of a wider group of punctuation and symbol characters whose shapes can be reused for very different purposes.
What Is the Keyboard Tilde ~?
~ is U+007E TILDE.
It is a standalone spacing symbol available on many computer keyboards. Unlike a combining accent, it occupies its own character position in the text.
Depending on the software or notation system, a tilde may appear in:
- command-line syntax;
- programming languages;
- regular expressions;
- configuration files;
- plain-text mathematical approximations;
- URLs and technical identifiers.
There is no single universal meaning for U+007E. The surrounding system defines what it does.
What Is the Tilde Operator ∼?
∼ is U+223C TILDE OPERATOR.
It belongs to Unicode’s Mathematical Operators block. Unicode associates it with meanings such as varies with, difference between, and similar to, while particular fields of mathematics can assign it additional conventional meanings.
For example:
a ∼ b
does not have one universal interpretation. The mathematical context determines what relationship the symbol expresses.
~ vs ∼
Compare:
~ — U+007E TILDE
∼ — U+223C TILDE OPERATOR
The first is a general-purpose keyboard character. The second is a mathematical symbol.
They may look nearly identical, but software sees different code points.
Why Is ~ Often Used Instead of ∼?
The main reason is convenience.
U+007E is available directly on many keyboards, while U+223C usually requires a symbol picker, mathematical editor, input method, or markup system.
As a result, plain-text mathematics may use:
a ~ b
when a typeset version might use:
a ∼ b
A human reader may understand the intended relationship, but the two expressions contain different Unicode characters.
Does ∼ Always Mean “Similar To”?
No.
The Unicode name TILDE OPERATOR identifies the character, not one universal mathematical interpretation.
Unicode lists several established uses, including varies with, difference between, and similar to. Other fields use the same symbol according to their own notation conventions.
This is common in mathematics: the character identity is fixed, while the intended meaning depends on context.
Is ~ an Approximation Sign?
The keyboard tilde is often used informally to mean “approximately”:
~10 minutes
or:
x ~ 5
But U+007E is not Unicode’s dedicated approximately-equal symbol.
Unicode contains several mathematical characters for related ideas, including:
| Symbol | Name | Code point |
|---|---|---|
| ∼ | TILDE OPERATOR | U+223C |
| ≃ | ASYMPTOTICALLY EQUAL TO | U+2243 |
| ≈ | ALMOST EQUAL TO | U+2248 |
These symbols are related in appearance or mathematical use, but they are not interchangeable characters.
Tilde ~ in Command-Line Environments
Some command-line shells give the tilde a special meaning related to user home directories.
For example:
~/Documents
may refer to a Documents directory inside the current user’s home directory.
This behavior belongs to the shell or command environment. Unicode itself does not define U+007E as “home directory.”
Tilde ~ in Programming
Programming languages assign their own meanings to the tilde.
In some languages it represents a bitwise operation. In others it appears in pattern matching, special operators, destructors, or other language-specific syntax.
Replacing a keyboard tilde with U+223C TILDE OPERATOR in source code changes the character sequence and may make the code invalid.
What Is the Small Tilde ˜?
Another similar character is:
˜ — U+02DC SMALL TILDE
This is a spacing modifier character. It should not be confused with either the keyboard tilde or the mathematical tilde operator.
| Symbol | Name | Code point |
|---|---|---|
| ~ | TILDE | U+007E |
| ˜ | SMALL TILDE | U+02DC |
| ∼ | TILDE OPERATOR | U+223C |
What Is the Combining Tilde ◌̃?
Unicode also contains U+0303 COMBINING TILDE.
A combining tilde attaches to the preceding base character instead of occupying its own ordinary spacing position.
For example, the letter ñ can be represented as the single precomposed character U+00F1, or in decomposed form as:
n + U+0303 COMBINING TILDE
In that use, the tilde is a diacritic rather than a mathematical relation or standalone punctuation-like symbol.
Spacing Tilde ~ vs Combining Tilde
The difference is structural.
~ U+007E is a standalone character.
U+0303 COMBINING TILDE attaches to another character.
They can share the same basic wave shape while behaving differently during cursor movement, text selection, normalization, and rendering.
What Is the Swung Dash ⁓?
Another wave-shaped character is:
⁓ — U+2053 SWUNG DASH
It belongs to general punctuation and is separate from both the keyboard tilde and mathematical tilde operator.
The existence of several wave-shaped Unicode characters is another reason visual identification alone can be unreliable.
Tilde ~ vs Wave Dash 〜
Unicode also contains:
〜 — U+301C WAVE DASH
This character is associated with East Asian text conventions.
It is typically much wider than the ASCII tilde, although appearance varies by font.
It should not be substituted for U+007E or U+223C merely because all three have a wave-like shape.
Why the Difference Matters in Mathematics
Mathematical software can recognize U+223C as a mathematical relation and give it mathematical spacing and behavior.
U+007E, by contrast, is a general-purpose symbol.
Compare:
a ~ b
a ∼ b
The expressions may look similar, but the second preserves the identity of the mathematical operator.
Why the Difference Matters in Code
Source code normally requires the exact characters defined by the language.
If a language expects:
~value
then replacing U+007E with:
∼value
changes the input and may make it invalid syntax.
How to Tell Which Tilde-Like Symbol You Have
Start with context:
- A tilde typed in source code or a command is likely U+007E.
- A tilde-shaped relation between mathematical expressions may be U+223C.
- A small raised spacing mark may be U+02DC.
- A tilde attached to a letter may be a combining diacritic.
- A wide wave in East Asian text may be U+301C.
Context can suggest the intended role, but copied text may still contain a substitute character.
If exact identity matters, paste the mark into What Is This Symbol and inspect the Unicode code point.
The Main Difference
- ~ is U+007E TILDE, a general-purpose keyboard character;
- ∼ is U+223C TILDE OPERATOR, a mathematical relation or operator;
- ˜ is U+02DC SMALL TILDE, a spacing modifier character;
- U+0303 is COMBINING TILDE, a diacritic that attaches to another character.
They share a wave-like shape, but their Unicode identities and text behavior are different.