Code on a screen, representing green threads.

Threads managed by a runtime, not the OS.

What green threads are

Green threads are threads that are managed by a runtime environment or library rather than directly by the operating system. While ordinary threads are scheduled by the operating system, green threads are scheduled by the program's own runtime. This different management gives green threads distinct characteristics, often making them more lightweight than threads handled by the operating system.

Managed by a runtime

The defining feature of green threads is who manages them. With green threads, the scheduling, that is, deciding which thread runs when, is handled by a runtime or library operating above the operating system. The operating system may be unaware of these threads, seeing only the program itself. This lets the runtime control concurrency on its own terms rather than relying on the operating system.

Lightweight concurrency

Because green threads are managed by the runtime rather than the operating system, they can be more lightweight, using fewer resources per thread. This can make it practical to have a very large number of them. The reduced overhead compared with operating-system threads is a key advantage, allowing programs to handle many concurrent tasks without the cost that native threads might impose.

Green threads versus native threads

Green threads differ from native threads, which the operating system schedules directly. Native threads can take advantage of the operating system's capabilities but may be heavier. Green threads trade some of that for lightweight efficiency and runtime control. The choice between them depends on the needs of the program and the trade-offs between overhead and the features the operating system provides.

Where green threads are used

Green threads are used in various runtimes and languages that want to provide lightweight concurrency managed by the program itself. They enable handling many concurrent tasks efficiently. Understanding green threads clarifies that there is more than one way to manage threads, and that moving scheduling into the runtime can offer lightweight, numerous threads.

Why it matters

Green threads are an important concept in concurrent programming. Understanding what they are - threads managed by a runtime rather than the operating system - clarifies a lightweight approach to concurrency. For anyone interested in how programs handle many concurrent tasks, it is a valuable concept to understand.

See also: What is a thread in programming?, What is a thread pool? Explained.

Sources

Published date reflects the original event date (2026-10-13). This article is original Skillo editorial written from the sources above; facts were verified in September 2026.

Skillo Staff

Skillo Staff

All stories by: Skillo Staff

Leave a Reply