Skip to main content

Standard Library



The Rascal Standard Library contains basic utility functions in relation to all built-in data structures, reusable tools (intermediate formats) for analysis and visualization of software languages, and language support for a number of common exchange formats and programming languages.


The basic Prelude modules that contain utility functions for daily usage are right here in the root of the library. To include them all in one go, use the Prelude module:

rascal>import Prelude;
rascal>println("Hello Rascal!");
Hello Rascal!

The IO module is otherwise most commonly used, because it contains Println.

The standard library has its own location scheme std:/// which can be used to explore its folder structure on the REPL. Note that source locations have auto-complete for the path component.

list[loc]: [

These are the entry points to the entire library:


  • The standard library comes with "batteries included", a number of reusable data-types and data-structures for building code analysis and manipulation tools. See for example Core.
  • Utility functions are sorted per data-type. So if you need something that operates on lists then look in the List module of the library. For sets look in Set, etc.
  • To process CSV, XML, JSON, YAML you will find utilities here, even support to access SQL databases via JDBC.


  • Prelude is a rather big collection of functions to have imported. It is sometimes better to cherry-pick the modules you need.
  • Some languages in Lang are not 100% tested and up-to-date. We are extracting these one-by-one to experimental library packages.