Short answer
- Software is a set of instructions that tells a computer what to do. The instructions are written by people in a programming language, translated into a form the computer can carry out, loaded into memory, and then executed one step at a time by the processor. An operating system sits between those instructions and the hardware. It loads programs, gives each program memory and processor time, and handles requests for files, screens, keyboards, networks, and other devices. Applications, such as a word processor or a web browser, are the programs most people use directly. Underneath them, system software keeps the machine organized and running. In short, software works because a computer can follow exact instructions very quickly. It takes input, works on data according to its instructions, and produces output.
What Software Is
Start with the simplest definition, because the rest of the guide builds on it. The National Institute of Standards and Technology defines software in its glossary as computer programs and associated data that may be dynamically written or modified during execution. In plain English, software is the instructions plus the data those instructions work with, as opposed to the physical machine itself.
Hardware is the part you can touch: the processor, memory chips, storage drive, screen, keyboard, and the circuits that connect them. Software is the part you cannot touch in the same way. You can see its effects on a screen or print its results, but the software itself is information stored as patterns in memory and on storage. A computer without software would have no useful task to perform. A program without hardware would have nothing to carry out its instructions.
That distinction explains why the same hardware can do so many different jobs. A laptop can edit a document, play a video, and run a video call, not because its circuits change, but because different software loads different instructions into memory.
It also explains why software can be copied more easily than a physical tool. A program is information, so copying it copies the instructions. A useful mental picture is a recipe. A recipe does not cook a meal by itself. A cook reads it and follows its steps in order. Software is closer to the recipe than to the cook. The computer follows the recipe exactly, including its mistakes. If a step is missing or in the wrong order, the result will be wrong, or the process will stop. Computers do not guess what you meant. They do what the instructions say.
The Main Kinds of Software
Not all software does the same job, and the layers matter when you try to understand how a program runs. Three broad groups cover most of what an ordinary user meets.
System software runs the computer itself. The operating system is the largest part of it. It starts when the computer starts, stays running while the computer is on, and manages the hardware on behalf of every other program. Drivers are another part of system software. A driver lets the operating system talk to a specific piece of hardware, such as a printer, without every application needing to know the details of that hardware.
Application software performs a task for a user. A word processor, a spreadsheet program, a photo editor, a web browser, and a game are all applications. They do not manage the whole computer. They ask the operating system for the services they need, and they focus on one kind of work.
Programming software is the software used to create other software. Editors, compilers, interpreters, and testing tools fall into this group. Source code does not turn itself into a running program. Another program does that work, as the next sections explain.
There is also software that sits close to the hardware and rarely changes, often called firmware. Firmware is low level software stored in a device that helps it start and perform basic functions. Some software is meant to be updated often, and some is meant to stay fixed unless the device maker changes it.
These layers work together. An application does not normally reach straight into the hardware. It asks the operating system, the operating system works with drivers and the hardware, and the result comes back up through the same layers.
Source Code: Instructions People Can Read
Before software can run, someone has to write it. The written form is called source code. Source code is text written in a programming language. It looks more structured than ordinary prose, because a computer needs exact rules, but it is still meant to be read and changed by people.
A tiny example makes the idea concrete. Imagine a program that adds tax to a price. In plain words, the steps might be:
- Take the price entered by the user.
- Take the tax rate.
- Multiply the price by the tax rate to get the tax amount.
- Add the tax amount to the price.
- Show the total.
In source code, those steps would be written with the symbols and rules of a particular language, with names for the values, such as price, tax rate, and total. The names help the human reader. The computer, after translation, works with the values themselves, not with the English meanings of the names.
Programming languages exist because writing directly in machine code would be slow, hard to read, and easy to get wrong. Machine code is the low level set of instructions a processor understands, made of binary patterns grouped into instructions such as add, move, compare, and jump. A programming language lets a person express an idea once, such as “add these two numbers,” and leave the detailed translation to another program.
Languages also give programmers building blocks: a loop to repeat a step, a condition to choose between steps, and a function to bundle steps under one name and reuse them. A large application is not one giant list of steps. It is many smaller parts, each with a clear job, connected in a planned way. Source code alone does not run. It is the plan. The next step is translation.
Compilation, Interpretation, and Bytecode
A processor cannot run source code directly, because source code is written for people. It must be translated into instructions the processor, or a program acting for the processor, can execute. The two classic methods are compilation and interpretation. Many modern systems use a mix of the two, so it helps to understand all three.
Compilation translates the whole source code into machine code before the program runs. A compiler reads the source code, checks it for errors it can detect, and produces an executable file. When you later run that program, the computer executes the machine code directly. The translation work is done in advance, but you usually need a separate step to build the program, and the machine code is often tied to a particular kind of processor and operating system.
Interpretation translates and executes the program as it runs. An interpreter reads the source code, or a prepared form of it, and carries out each instruction in turn. You do not need a separate build step in the same way, which can make testing and changing a program quicker.
Bytecode sits between those two ideas. Source code is first compiled into bytecode, a compact set of instructions for a virtual machine rather than for a physical processor. Then a virtual machine, which is itself software, executes the bytecode. The Python documentation describes this pattern in its py_compile module, which compiles a source file to bytecode and writes out a bytecode cache file. That cached file does not run on its own. It still needs the Python runtime to execute it. The benefit is portability in many cases. The cost is an extra layer between the program and the hardware.
This is why labels such as “compiled language” and “interpreted language” can mislead if taken too literally. What matters is the pipeline for a particular implementation. Some languages are usually compiled to machine code. Some are usually run through an interpreter. Some, such as Python in its common CPython implementation, are compiled to bytecode and then interpreted by a virtual machine. The useful takeaway is that translation always happens somewhere.
Errors also appear at different stages depending on the pipeline. A compiler may catch a mistake before the program ever runs, because it checks the whole source code first. An interpreter may only reach a mistake when it gets to that part of the program during execution.
How a Program Runs, Step by Step
The steps below describe a typical program on a typical personal computer. Details vary by operating system and by program, but the overall pattern holds.
First, the program is stored. Before it runs, it sits on a storage drive as a file or a set of files. Storage keeps information when the power is off.
Second, the operating system loads the program into memory. When you open an application, the operating system reads the program from storage and places its instructions and starting data into memory, fast working space for programs that are currently running. It also creates a process for the program. A process is the operating system’s view of a running program, including its code, its current activity, and the resources it has been given, such as memory and open files. OpenStax describes a process in exactly this way: it includes the program code, its current activity represented by the program counter, and a set of resources.
Third, the processor begins to execute instructions. The University of British Columbia Okanagan course notes on computer organization describe the fetch and execute cycle in five parts: instruction fetch, instruction decode, data fetch, instruction execution, and result return. In plain terms, the processor fetches an instruction from memory, works out what it means, fetches any data it needs, carries out the operation, and stores the result where the next step can find it. A special register called the program counter keeps track of the next instruction to execute.
Fourth, the program responds to input. Input can come from a keyboard, a mouse, a touch screen, a file, or a network connection. The program does not watch the hardware directly in most cases. It asks the operating system for input, and the operating system delivers it. Pressing a key in a word processor, for example, leads to a chain of steps: the key press is reported, the program updates its stored text, and it asks the operating system to show the changed text on the screen.
Fifth, the program works on data in memory. While it runs, it keeps values it needs in memory: the text of a document, the numbers in a spreadsheet, or the address of a web page it is loading. Memory is fast, but it is temporary. OpenStax notes that the operating system mediates access to memory for volatile storage, while disks and flash memory provide persistent storage. That is why unsaved work can be lost if power is cut. The work exists in memory, not yet in a saved file on storage.
Sixth, the program produces output: text on a screen, sound through speakers, a printed page, a saved file, or data sent over a network. In each case, the program asks the operating system to perform the output step.
Seventh, the program saves data when asked, or when it is designed to do so automatically. Saving writes data from memory to a file on storage, in a format the program can read again later. A document file is not just the visible text. It also contains information about fonts, spacing, and images, organized according to rules the program understands.
Eighth, the program ends, or it waits. When you close an application, the operating system reclaims its memory and other resources so other programs can use them. Some programs keep running in the background, waiting for an event, such as a new message. Even then, they are waiting for the operating system to wake them when something they care about happens.
A worked example pulls this together. Suppose you open a text document, type a sentence, then save it.
- You open the document from inside the word processor.
- The operating system loads the word processor into memory and creates a process for it.
- The word processor asks the operating system to open the document file, reads its contents from storage into memory, and shows the text on screen.
- The processor runs the program’s instructions in the fetch and execute cycle while the program waits for input.
- Each key you press becomes input. The program adds the character to the text in memory and asks the operating system to redraw the screen.
- When you choose Save, the program writes the updated text, with its formatting information, from memory back to the document file on storage.
- When you close the program, the operating system releases its memory, and the saved file remains on storage.
Nothing in that chain requires the computer to understand the meaning of your sentence. It stores characters, follows rules for displaying them, and writes them to a file. Meaning comes from the reader, not from the machine.
Operating Systems: The Manager in the Middle
OpenStax defines an operating system as the core piece of software that typically manages and controls the interconnection of hardware and software on a computer, loaded upon start up, and needed to operate any computerized device.
Its first job is resource management. A computer has limited processor time, memory, storage space, and device capacity, and several programs often want those resources at once. The operating system decides which program gets processor time, how much memory each program may use, and how requests for devices are ordered. It also keeps programs separate, so that one program cannot easily overwrite another program’s memory or data by accident. OpenStax stresses isolation for this reason: multiple programs running on the same processor and memory should operate independently without interfering with each other’s execution or data.
Its second job is to provide services through a consistent interface. Applications typically do not directly manipulate the hardware. Instead, they ask the operating system to do this on their behalf, according to OpenStax. When a program wants to open a file, show a window, or send data over a network, it makes a request to the operating system, and the operating system carries out the low level work. This is why the same application can often work with different printers or storage drives. The application talks to the operating system, and the operating system talks to the specific hardware through drivers.
Its third job is to manage files and storage. The operating system organizes storage into files and folders, keeps track of where each file is stored, and controls who may read or change it.
Its fourth job is to provide a way for people to interact with the computer, through a graphical interface with windows, icons, and menus, or a text interface where the user types commands. The interface is part of what makes the computer usable, but it is not the whole operating system. The resource management and services underneath it are just as important, even though they are less visible.
In short, the operating system is the manager, applications are the workers, and hardware is the workshop. Workers ask the manager for tools and space. The manager keeps track of who has what and prevents workers from interfering with each other. That management is what lets you run a browser, a music player, and a document editor at the same time on one machine.
Applications: What You Actually Use
Applications are the visible face of software. They take a general purpose machine and turn it into a tool for a specific job. A web browser turns the machine into a window onto web pages. A spreadsheet program turns it into a calculator for tables of numbers. A photo editor turns it into a darkroom for digital images.
An application works by combining its own instructions with services from the operating system and, often, with libraries of ready made code. A library is a collection of routines that many programs can use, such as routines for drawing windows or reading common file formats. Using libraries saves programmers from rewriting the same basic functions for every program. The National Institute of Standards and Technology glossary mentions application code and libraries together when it describes software that may be modified during execution, which reflects how common libraries are in real programs.
Applications also store settings and data separately from their own code. Your preferences, your recent files, and your saved work are data, not part of the program’s instructions. That separation is why you can update an application and keep your documents. It is also why two people using the same application can have very different results. The instructions are the same. The data they feed into the program is different.
Some applications run entirely on your device. Others work with a server over a network. In the second case, part of the work happens on your device, such as showing the interface, and part happens on a remote computer, such as storing shared data. The basic pattern is unchanged: instructions run, data moves, and output returns. A program that needs a network connection cannot complete a network task without one.
Data and Files: What Software Works On
Software without data does very little. Data is the information a program reads, changes, and writes: text you type, numbers in a table, pixels in a photo, or settings that tell a program how you like it to behave.
A file is how data is stored on a storage device under a name. Inside the file, the data is stored as bytes, small units of binary information. A program that opens a file must understand the file’s format, the rules for how those bytes are organized. If it does not understand the format, it cannot make sense of the contents, even though the bytes are present.
That is why file extensions are useful but not magic. An extension is a hint about the format, not a guarantee. The real test is whether a program can read the bytes according to the format’s rules. Converting a file from one format to another means rewriting the same information according to a different set of rules, which is why some features may change or be lost in conversion.
Memory and storage play different roles, and confusing them is a common source of trouble. Memory is the fast, temporary working space where running programs and their current data live. Storage is the persistent space where files live when programs are not running. When you open a file, a copy of its data moves from storage into memory. When you save, updated data moves from memory back to storage. Until you save, your latest changes exist mainly in memory, which is why a power cut or a crash can lose unsaved work even though the program itself is still installed.
Common Misconceptions
Several misunderstandings make software seem stranger than it is.
Software is not the same as the internet. A program can run entirely on your device with no network connection, as long as it does not need data from elsewhere. The internet is a network that lets programs on different machines exchange data. It is a service software can use, not the software itself. A web browser without a network connection can still open, but it cannot fetch new web pages, because the pages live on other machines.
Deleting an icon does not always delete a program. On many systems, an icon is a shortcut, a pointer to the program, not the program itself. Removing the shortcut hides the pointer, while the program files may remain until they are uninstalled through the proper step.
A computer does not understand meaning. It follows rules for symbols. When a spell checker flags a word, it is comparing symbols against a list. Good software is designed around this limit by giving the machine clear, checkable rules.
Faster hardware does not fix every slow program. If a program waits for a network response, a faster processor alone may not help much. Performance depends on the instructions, the data, the operating system, the hardware, and the network together.
An update does not mean the old version was worthless. Software is changed to fix mistakes, to handle new hardware or file formats, to close security problems, and to add features. The update must be tested, because a change in one part of a program can affect other parts.
Finally, a bug is not always a sign that the whole program is broken. A bug is a mistake in the instructions, or in how they handle an unexpected case. It may affect only one feature or only certain data.
Frequently Asked Questions
What is software in simple terms?
Software is a set of instructions that tells a computer what to do, together with the data those instructions work with. Hardware is the physical machine. Software is the information that directs it.
How does software turn into actions on a screen?
Source code is translated into machine code, bytecode, or another executable form. The operating system loads the program into memory, the processor executes its instructions in the fetch and execute cycle, and the program asks the operating system to draw results or save files. The screen shows the output of that chain, not the code itself.
What is the difference between a program and an application?
A program is a general term for a set of instructions that a computer can execute. An application is a kind of program designed for a user task, such as writing, browsing, or editing photos. System software, such as an operating system, is also made of programs, but its job is to run the computer rather than to perform one user task.
What is source code?
Source code is the human readable text of a program, written in a programming language. Before it runs, it is translated by a compiler, an interpreter, or a bytecode system into instructions a processor or virtual machine can execute.
What is the difference between compilation and interpretation?
Compilation translates source code into machine code before the program runs. Interpretation translates and executes the program as it runs. Bytecode is a middle path: source code is compiled into bytecode for a virtual machine, which then executes it.
Why does a program need an operating system?
The operating system manages processor time, memory, storage, files, and devices, and it keeps running programs separate. Applications ask the operating system for those services instead of managing the hardware themselves.
Where is my work stored when I have not saved yet?
Mainly in memory, which is fast but temporary. Saving copies the updated data from memory to a file on storage, which keeps it when the power is off. Until you save, a power cut or a crash can lose recent changes.
Why does the same program work differently on different computers?
Because the full system differs: the operating system version, the hardware, the memory and storage, the installed libraries and drivers, and the network connection can all change how a program behaves. The instructions may be the same, but the environment they run in is not.
Is software the same as a file?
No. A program is often stored as one or more files, and it works on files as data, but the two roles are different. Program files contain instructions. Data files contain information for those instructions to read and change.
Can software run without hardware?
No. Software is instructions, and instructions need something to carry them out. A program stored on a drive but never loaded into memory and executed by a processor is not running.
Sources & references
- National Institute of Standards and Technology, Computer Security Resource Center glossary, term "software": computer programs and associated data that may be dynamically written or modified during execution, and the related firmware and hardware entries.
- OpenStax, Introduction to Computer Science, section 6.1 "What Is an Operating System?": operating system as the core software managing hardware and software, applications asking the operating system rather than directly manipulating hardware, isolation of programs, process contents, and volatile memory versus persistent storage.
- Python Software Foundation, Python documentation, py_compile module: compiling a source file to bytecode and writing out a bytecode cache file.
- University of British Columbia Okanagan, COSC 122 course notes on computer organization by Dr. Ramon Lawrence: von Neumann architecture with CPU and memory storing both instructions and data, CPU components including control unit, arithmetic and logic unit, and registers, and the fetch and execute cycle steps.