Computer storage, computer memory, and often casually memory refer to computer components, devices and recording media that retain digital data used for computing for some interval of time. Computer storage provides one of the core functions of the modern computer, that of information retention. It is one of the fundamental components of all modern computers, and coupled with a central processing unit (CPU), implements the basic Von Neumann computer model used since the 1940s.
In contemporary usage, memory usually refers to a form of solid state storage known as random access memory (RAM) and sometimes other forms of fast but temporary storage. Similarly, storage more commonly refers to mass storage - optical discs, forms of magnetic storage like hard disks, and other types of storage which are slower than RAM, but of a more permanent nature. These contemporary distinctions are helpful, because they are also fundamental to the architecture of computers in general. As well, they reflect an important and significant technical difference between memory and mass storage devices, which has been blurred by the historical usage of the terms "main storage" (and sometimes "primary storage") for random access memory, and "secondary storage" for mass storage devices. This is explained in the following sections, in which the traditional "storage" terms are used as sub-headings for convenience.
The fundamental components of a general-purpose computer are arithmetic and logic unit, control circuitry, storage space, and input/output devices. If storage is removed, a computer can only function as a digital signal processing device (e.g. calculator, media player). The ability to store instructions that form a computer program, and the information that the instructions manipulate, is what makes stored program architecture computers versatile enough for general purposes.
A digital computer represents information using the binary numeral system. Text, numbers, pictures, audio, and nearly any other form of information can be converted into a string of bits, or binary digits, each of which has a value of 1 or 0. The most common unit of storage is the byte, equal to 8 bits. A piece of information can be manipulated by any computer whose storage space is large enough to accommodate the corresponding data, or the binary representation of the piece of information. For example, a computer with a storage space of eight million bits, or one megabyte, could be used to edit a small novel.
Various forms of storage, based on various natural phenomena, have been invented. So far, no practical universal storage medium exists, and all forms of storage have some drawbacks. Therefore a computer system usually contains several kinds of storage, each with an individual purpose, as shown in the diagram.