9 (nine) is the
natural number
In mathematics, the natural numbers are the numbers 0, 1, 2, 3, and so on, possibly excluding 0. Some start counting with 0, defining the natural numbers as the non-negative integers , while others start with 1, defining them as the positive in ...
following and preceding .
Evolution of the Hindu–Arabic digit

Circa 300 BC, as part of the
Brahmi numerals
Brahmi numerals are a numeral system attested in the Indian subcontinent from the 3rd century BCE. It is the direct graphic ancestor of the modern Hindu–Arabic numeral system. However, the Brahmi numeral system was conceptually distinct from ...
, various Indians wrote a digit 9 similar in shape to the modern closing
question mark
The question mark (also known as interrogation point, query, or eroteme in journalism) is a punctuation, punctuation mark that indicates a question or interrogative clause or phrase in many languages.
History
The history of the question mark is ...
without the bottom dot. The Kshatrapa, Andhra and Gupta started curving the bottom vertical line coming up with a -look-alike. How the numbers got to their Gupta form is open to considerable debate. The Nagari continued the bottom stroke to make a circle and enclose the 3-look-alike, in much the same way that the sign @ encircles a lowercase ''a''. As time went on, the enclosing circle became bigger and its line continued beyond the circle downwards, as the 3-look-alike became smaller. Soon, all that was left of the 3-look-alike was a squiggle. The Arabs simply connected that squiggle to the downward stroke at the middle and subsequent European change was purely cosmetic.
While the shape of the glyph for the digit 9 has an
ascender in most modern
typeface
A typeface (or font family) is a design of Letter (alphabet), letters, Numerical digit, numbers and other symbols, to be used in printing or for electronic display. Most typefaces include variations in size (e.g., 24 point), weight (e.g., light, ...
s, in typefaces with
text figures
Text figures (also known as non-lining, lowercase, old style, ranging, hanging, medieval, billing, or antique figures or numerals) are numerals designed with varying heights in a fashion that resembles a typical line of running text, hence the ...
the character usually has a
descender, as, for example, in

.
The form of the number nine (9) could possibly derived from the Arabic letter ''
waw'', in which its isolated form (و) resembles the number 9.

The modern digit resembles an inverted ''6''. To disambiguate the two on objects and labels that can be inverted, they are often underlined. It is sometimes handwritten with two strokes and a straight stem, resembling a raised lower-case letter q, which distinguishes it from the 6. Similarly, in
seven-segment display
A seven-segment display is a display device for Arabic numerals, less complex than a device that can show more characters such as dot matrix displays. Seven-segment displays are widely used in digital clocks, electronic meters, basic calculators, ...
, the number 9 can be constructed either with a hook at the end of its stem or without one. Most
LCD
A liquid-crystal display (LCD) is a flat-panel display or other electronically modulated optical device that uses the light-modulating properties of liquid crystals combined with polarizers to display information. Liquid crystals do not em ...
calculators use the former, but some
VFD models use the latter.
Mathematics
9 is the fourth
composite number
A composite number is a positive integer that can be formed by multiplying two smaller positive integers. Accordingly it is a positive integer that has at least one divisor other than 1 and itself. Every positive integer is composite, prime numb ...
, and the first odd composite number. 9 is also a
refactorable number.
Casting out nines is a quick way of testing the calculations of sums, differences, products, and
quotient
In arithmetic, a quotient (from 'how many times', pronounced ) is a quantity produced by the division of two numbers. The quotient has widespread use throughout mathematics. It has two definitions: either the integer part of a division (in th ...
s of
integer
An integer is the number zero (0), a positive natural number (1, 2, 3, ...), or the negation of a positive natural number (−1, −2, −3, ...). The negations or additive inverses of the positive natural numbers are referred to as negative in ...
s in
decimal
The decimal numeral system (also called the base-ten positional numeral system and denary or decanary) is the standard system for denoting integer and non-integer numbers. It is the extension to non-integer numbers (''decimal fractions'') of th ...
, a method known as long ago as the 12th century.
9 is the only square number that is the sum of two consecutive, positive cubes:
If an
odd perfect number
In number theory, a perfect number is a positive integer that is equal to the sum of its positive proper divisors, that is, divisors excluding the number itself. For instance, 6 has proper divisors 1, 2 and 3, and 1 + 2 + 3 = 6, so 6 is a perfec ...
exists, it will have at least nine distinct
prime factor
A prime number (or a prime) is a natural number greater than 1 that is not a product of two smaller natural numbers. A natural number greater than 1 that is not prime is called a composite number. For example, 5 is prime because the only ways ...
s.

9 is the sum of the
cubes
A cube or regular hexahedron is a three-dimensional space, three-dimensional solid object in geometry, which is bounded by six congruent square (geometry), square faces, a type of polyhedron. It has twelve congruent edges and eight vertices. It i ...
of the first two non-zero positive integers
which makes it the first cube-sum number greater than
one
1 (one, unit, unity) is a number, numeral, and glyph. It is the first and smallest positive integer of the infinite sequence of natural numbers. This fundamental property has led to its unique uses in other fields, ranging from science to sp ...
. A number that is 4 or 5
modulo
In computing and mathematics, the modulo operation returns the remainder or signed remainder of a division, after one number is divided by another, the latter being called the '' modulus'' of the operation.
Given two positive numbers and , mo ...
9 cannot be represented as the
sum of three cubes.

There are nine
Heegner number
In number theory
Number theory is a branch of pure mathematics devoted primarily to the study of the integers and arithmetic functions. Number theorists study prime numbers as well as the properties of mathematical objects constructed from int ...
s, or
square-free positive integers that yield an imaginary
quadratic field
In algebraic number theory, a quadratic field is an algebraic number field of Degree of a field extension, degree two over \mathbf, the rational numbers.
Every such quadratic field is some \mathbf(\sqrt) where d is a (uniquely defined) square-free ...