Before touching Groovy, you need to master basic programming concepts and the JVM ecosystem. In this episode you set up the JDK and the Groovy SDK, choose an IDE that supports Groovy, and verify your first installation with a simple script.

Welcome to the Learn Groovy series! This series will take you to mastery of Groovy — a dynamic scripting language that runs on the JVM — from the foundations of the concepts all the way to production readiness. There are 23 episodes in total, organized into six phases.
Before touching groovy, there are a few basic skills and pieces of software you must have. Groovy is not a complicated language, but it stands on top of the large JVM ecosystem, so an understanding of Java and the JVM will make your journey much smoother.
Episode 0 is your roadmap: making sure your basic skills are in place, setting up the JDK and the Groovy SDK, choosing an IDE, and doing the first verification. Once this episode is done, the entire series can be followed comfortably.
Groovy is a very concise language, but universal programming principles still apply. You should be comfortable with variables, control flow such as if and loops, and functions or methods. All three are used in nearly every episode of this series.
What's even more important: you need to understand that Groovy is a dynamic language. Data types are determined at runtime, and def is the keyword for declaring variables without an explicit type. This concept differs from Java and will be a recurring thread throughout the series.
Groovy is compiled into bytecode that runs on the Java Virtual Machine (JVM). This means Groovy can call any Java library, and Groovy code can run side by side with Java applications. You need to understand the following terms:
Because you share the JVM, all your Java knowledge won't go to waste. This is also what makes episode 10 about Java integration feel so natural.
You'll interact a lot with the terminal to run scripts and builds. Master basic navigation such as cd, ls, and echo. For writing code, prepare an IDE that supports Groovy, and get used to a build tool such as Gradle or Maven.
The cleanest way to install Groovy is through SDKMAN — a JVM-based SDK manager. First make sure the JDK is installed:
sdk install javaOnce the JDK is done, install Groovy:
sdk install groovySDKMAN automatically suggests the latest stable version. The Groovy version used in this series is 4.x, which is compatible with Java 8 through 23. After installation, verify both:
java -version
groovy --versionIf you don't use SDKMAN yet, the alternatives are brew install groovy on macOS or a distro package on Linux, for example apt install groovy. The sdk install groovy command above is the most recommended approach because it makes switching versions easy — a need we'll cover in episode 19.
You're free to choose the IDE that fits your taste:
All of these IDEs understand build.gradle and Groovy projects well. For quick practice, Groovy's built-in groovyConsole is enough to run code snippets without assembling a full project.
Groovy itself doesn't require a build tool, but for real projects you'll use Gradle, whose build scripts are written in Groovy. Install it via SDKMAN:
sdk install gradleFinally, set up Git for version management:
git --versionCreate a file named halo.groovy with the following single line:
println "Halo dari Groovy!"Run it from the terminal:
groovy halo.groovyIf the output shows Halo dari Groovy!, your environment is ready. A quick alternative for testing a single line without creating a file:
groovy -e "println 'Halo dari Groovy!'"The groovy -e "println 'Halo dari Groovy!'" command executes a Groovy expression directly without a file — a useful pattern for quick experiments throughout the series.
Besides script files, Groovy provides an interactive REPL called groovysh. Run it from the terminal:
groovyshInside the REPL, you can type println 2 + 3 and press Enter, and Groovy immediately evaluates the result. This REPL will be very helpful when you want to quickly test syntax or library behavior without creating a file.
Here's what you need to have prepared by episode 0:
If anything is still missing, complete it before moving on. A strong foundation will make the next 22 episodes feel much lighter.
In episode 0 you set up the footing for the entire series: understanding the basic programming skills and the JVM ecosystem, installing the JDK and the Groovy SDK via SDKMAN, choosing an IDE, and verifying the installation with your first script.
The key takeaways:
def is the keyword for declaring variables without an explicit type.groovy --version and a simple script.groovysh provides a REPL for quick experiments.In episode 1 next, we'll discuss the history, background, and why to choose Groovy — from Groovy's birth in the early 2000s, its comparison with Java, Kotlin, and Scala, to the advantages of concise syntax, metaprogramming, and DSLs. Make sure your environment is ready, because the Learn Groovy journey has just begun!