The Java Development Kit includes the JRE, javac, JavaDoc, a debugger, and other tools for building and running Java programs. See how the JDK, JRE, and JVM fit together—and why the runtime alone isn’t enough to create Java software.

Multiple Choice

Which of the following is included in the JDK?

The JDK is the complete package developers use to write, compile, and debug Java programs. It includes the Java Runtime Environment so you can run programs, plus the Java compiler (javac) that translates your Java source into bytecode, JavaDoc for generating API documentation, the Java debugger, and other development tools. Because the JDK contains the JRE, you get both the runtime and the development tools in one bundle, which is why it’s the full kit for Java development. The JavaScript development toolkit isn’t part of the JDK, and having only the Java Virtual Machine would leave out the essential compiler and other tools needed to develop apps.

What’s Inside the Java Development Kit?

Writing a Java program takes more than a text editor and a clever idea. You also need tools to turn your code into something a computer can run, check for errors, and explain how a project is meant to work. That collection of tools is the Java Development Kit, usually called the JDK. Think of it as a workshop: it has the machinery for building a program, along with what’s needed to run it.

The JDK includes a Java compiler, documentation tools, debugging tools, and other utilities. It also provides the components needed to run Java applications. That mix is what makes it a development kit, rather than just a way to launch programs.

First, the big three: JDK, JRE, and JVM

Java’s basic vocabulary can sound like a bowl of alphabet soup. The terms are related, but they describe different parts of the system.

The Java Virtual Machine, or JVM, runs Java bytecode. Bytecode is the form Java source code takes after compilation. The JVM reads that bytecode and carries out its instructions on a particular computer. Because JVMs exist for many operating systems and hardware types, the same Java program can often run across different platforms with few or no code changes.

The Java Runtime Environment, or JRE, provides what a computer needs to run Java applications. Traditionally, it included the JVM and the core Java libraries that programs rely on. If someone only needed to run a Java application, a JRE could be enough.

The Java Development Kit, or JDK, is built for people who create Java software. It includes development tools such as the compiler, as well as runtime components. In the traditional packaging model, the JDK contained the JRE: the JRE contained the JVM, and the JDK added the tools for building and maintaining programs.

A simple way to picture the relationship is this: the JVM runs the instructions, the JRE supplies the runtime environment, and the JDK adds the workshop tools. Each layer has a different job.

The compiler turns source code into bytecode

One of the JDK’s central tools is javac, the Java compiler. A developer writes source code in files that commonly end with .java. The compiler checks that code and, when it’s valid, converts it into bytecode, typically stored in .class files.

That conversion is a bit like translating a recipe into a format a kitchen can follow. The source code is written in a language people can read and edit; bytecode is designed for the JVM to interpret or compile further as the program runs.

For example, a small Java file might contain a main method, which marks a starting point for many applications. A developer can compile it from a command line with javac, then run the resulting class with the Java launcher. In a larger project, tools such as Maven or Gradle can manage compilation and other build steps, but the JDK’s compiler remains a key part of the process.

The compiler also catches many kinds of errors before a program runs. A missing semicolon or a type mismatch can stop compilation, giving the developer a chance to fix the issue early. Not every bug gets caught this way, of course. Logic errors can slip through, and a program can compile perfectly while still doing something unexpected.

Documentation is part of the toolkit, too

The JDK includes Javadoc, a tool that generates API documentation from specially formatted comments in Java source code. An API is the set of classes and methods that other parts of a program can use. Good documentation makes those pieces easier to understand.

Javadoc can turn comments into linked HTML pages, including descriptions of classes, methods, parameters, and return values. That’s useful when a team shares a library or when developers revisit code months later and wonder why a method has a particular name. A clear explanation can save more time than a clever shortcut.

Documentation tools may seem less exciting than compilers, but they help software last. Code gets passed between people, grows, and changes. If its purpose is hidden, even a well-built program can become hard to maintain.

Debugging tools help explain what went wrong

The JDK also includes tools for debugging Java programs. jdb, the Java Debugger, can help developers inspect a program as it runs. They can pause execution, examine values, and follow the path the program takes.

That matters because a bug rarely announces itself with a neat label. A program might crash far from the line that caused the trouble, or produce a result that looks plausible but is wrong. A debugger lets developers slow things down and inspect the program’s state—rather like opening the hood instead of guessing from the sound of the engine.

Many developers use graphical tools inside an integrated development environment (IDE), such as IntelliJ IDEA or Eclipse. These environments often provide their own debugger interface, but they still work with the Java platform and its development tools. The command-line tools remain useful, especially for automation, build servers, or a quick check when a full IDE would be overkill.

Other JDK tools fill in the gaps

The compiler and debugger get much of the attention, but the JDK includes other utilities for development tasks. Depending on the JDK version and distribution, these may help inspect class files, launch applications, generate archives, or create and manage certificates.

For instance, the Java launcher starts Java applications, while tools such as jar can package related files into an archive. Developers may also use utilities to examine bytecode or manage security-related data. The exact collection can vary across releases, so it’s worth checking the documentation for the JDK version in use.

This is one reason the JDK is more than a single application. It’s a collection of components that work together. A team might rely on only a few tools each day, then reach for another one when diagnosing a stubborn issue or setting up a deployment pipeline.

A small historical wrinkle

The relationship between the JDK and JRE is often described as though every modern installation comes with a separate, neatly packaged JRE. That description reflects the traditional Java packaging model, but current distributions don’t always present the pieces that way.

Since Java 9, the platform has been modular. Many current JDK distributions don’t include a separate JRE directory or offer a standalone JRE download in the old style. Developers can still use the JDK to run Java programs, and tools such as jlink can create a smaller runtime image containing selected modules. The packaging changed; the core idea did not: development requires tools that a basic runtime alone doesn’t provide.

It’s also easy to confuse Java with JavaScript because their names sound alike. They’re different programming languages, with different histories and ecosystems. A JavaScript toolkit isn’t a component of the JDK. The JDK is specifically for working with Java and the tools built around it.

Why the JDK matters

A runtime can launch an application, but it doesn’t provide the full set of tools for building one. The JDK brings together the compiler, runtime support, documentation generator, debugger, and related utilities. That makes it the standard foundation for Java development, whether someone is creating a small command-line program or contributing to a large service.

Once you know what each piece does, the names become easier to keep straight. The JVM runs bytecode. The JRE traditionally packages the runtime components. The JDK supplies the development tools and, in the traditional model, includes the runtime as well. Together, those pieces form a practical toolkit for writing, compiling, documenting, debugging, and running Java software.