Library / SDK
tsoding/nob.h avatar
tsoding/nob.h

nob.h turns the build recipe into the same C code you already wrote

Header only library for writing build recipes in C.

3,429 stars218 forksC++NOASSERTION

At a glance

What is it?
tsoding/nob.h is one header file that you copy into a project so the build logic is compiled by the same toolchain as the program. The author is blunt about the scope: no make, no cmake, no shell, and no claim that it suits your project.
Who is it for?
nob.h fits small to medium C and C++ projects that already have a compiler and no complex dependency graph, and it fits people who would rather read a build script than a DSL. Skip it if cmake manages many modules for you, since the author says so directly.
Can I use it commercially?
Check first. The repository uses a licence we do not classify automatically, so read its LICENSE file before any commercial use.
Is it still maintained?
Yes. The repository last received commits 18 days ago.
What is it written in?
Mainly C++, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on November 15, 2026, and from our analysis. They are not legal advice.

From daily snapshots

Star history

  • tsoding/nob.h3,429 ★ · +150
Star history
Repository2026-09-242026-11-15
tsoding/nob.h3.3k3.4k

150 Stars in the last 52 days, measured from the daily GitHub snapshot. Compare with other projects

Editorial analysis

One header is the entire install step

There is no package manager path here. The only file you need from the repository is nob.h itself, served as a raw file from the main branch, and the instruction is to copy-paste it to your project and start using it. Examples live in a how_to/ folder inside the repository rather than in a published package, so the documentation for the library is a set of working programs rather than a reference manual. That arrangement has one clear advantage and one clear cost. The advantage is that the dependency cannot drift, because there is no version to resolve: what you paste is what you run. The cost is that there is no upgrade path either. There are no GitHub releases for this repository, so a version number does not exist to pin, and the only way to see what changed is to look at the branch.

The tree is broader than header only

The repository description calls this a header only library for writing build recipes in C, but the top level carries more than the header. A nob.c file sits beside nob.h, and shared.h sits beside that, so at least part of the design lives in translation units rather than in the single header you paste. Three directories support the header: tasks/, tests/ and tools/, with how_to/ holding the examples. Then there is the ordinary scaffolding of .github/, .gitignore, CONTRIBUTING.md and LICENSE. The LICENSE file is present, but the licence field for the repository reads NOASSERTION, which means no licence was recognised from it, so check the file rather than a badge. The primary language recorded for the repository is C++ even though the code and the whole premise are C.

The author rules the project out of scope himself

Three separate sections of the README push back on adoption. The first is headed as an experimental project and says the author is not sure this is even a good idea, that this is why he is implementing it, that it is a research project, and that he is making no claims about suitability for any project. The second is headed with a warning that it is likely not suitable for your project, and the argument is cmake users specifically: if you are managing tons of modules and tons of dependencies you probably do not want this tool, followed by the aside that in that case the author thinks you have a much bigger problem than a build system. The third is the previous iteration at tsoding/nobuild, which gets a flat recommendation against. The only positive claim is personal and narrow: it works quite well for me there, in the author's own C projects.

Use C more appears in both lists

The advantages and the disadvantages each contain the same bullet, worded identically: you get to use C more. The lists are otherwise different in kind. On the advantage side you get extremely portable builds across Linux, MacOS, Windows, FreeBSD and other systems, achieved by reducing dependencies to just a C compiler; and you end up using the same language for developing and building, which may enable code reuse strategies, because the build system can use the code of the project itself directly and the project can use the code of the build system directly. On the disadvantage side you need to be comfortable with C and implementing things yourself, since this is like writing shell scripts but in C, and it probably does not make any sense outside C or C++ projects. Both lists end with an ellipsis, so neither is presented as complete.

The same language both ways is the real claim

Strip out the naming philosophy and one engineering claim remains, and it is the reason to care. In a conventional setup the build tool and the product live in different languages, so anything shared between them has to be duplicated or exposed through a subprocess. The README states the opposite arrangement: the build system can use the code of the project itself directly, and the project can use the code of the build system also directly. Two consequences follow from that. A version constant or a generated list of source files has one definition that both sides compile. And the bootstrap is circular but short, because the build file is itself a C program that the C compiler compiles, which is what the idea section means by bootstrapping your build system with the compiler and then using that build system for everything else.

Portability is bought by deleting the dependency list

The stated requirement is that you should not need anything but a C compiler to build a C project, and the exclusions are enumerated rather than implied: no make, no cmake, no shell, no cmd, no PowerShell. The portability claim follows directly from that list rather than from any porting work, since a C compiler exists on essentially every platform these days, and the systems named are Linux, MacOS, Windows and FreeBSD with the wording including but not limited to. What you give up is not incidental. CMake configuration files, package managers, cross-compilation toolchain descriptions and CI matrices all assume a task runner with its own language and its own install path. Deleting them moves that cost onto you, which is why the disadvantages section leads with needing to be comfortable implementing things yourself.

Four other languages already have a nobuild

The README argues the idea is not C specific and points at implementations elsewhere. For C++ there is nabs by zhiayang. For Java there are two, arris hosted on GitLab under NikaDev and job hosted on Codeberg under ptrace. For Fortran there is fob.f90 hosted on Codeberg under shascilowicz. Each sits in a different forge, which says something about how informal the movement is: there is no shared specification, only the shared idea of writing the recipe in the language you already have. The section closes with an invitation to contribute more, which is consistent with the header-only distribution model. If you write the pattern in a language the list does not cover, copying one file into your project is the whole cost of trying it.

Editorial conclusion

nob.h fits small to medium C and C++ projects that already have a compiler and no complex dependency graph, and it fits people who would rather read a build script than a DSL. Skip it if cmake manages many modules for you, since the author says so directly. Before using it, copy the header into your own tree as the project instructs rather than vendoring the repository, and read how_to/ first, because the whole library is that one file and its examples are the documentation.

Frequently asked questions

what is nob h

nob.h is a header only library for writing build recipes in C, described as the next generation of the NoBuild idea. The only file you need is nob.h itself: copy-paste it into your project and start using it, with worked examples in the how_to/ folder of the repository.

What is nob?

nob stands for nobuild, chosen because it is shorter and more suitable as a prefix for a library. The NoBuild idea is that a C project should need nothing but a C compiler to build: no make, no cmake, no shell, no cmd and no PowerShell.

What is nob slang for?

The project does not present nob as slang. It shortens nobuild, and places the name alongside NoSQL, No-code and Serverless as movements that supposedly remove the root cause of a problem, with the stated motivation that there were too many problems with the process of building C projects.

Official sources

  1. Issues
  2. README
  3. tsoding/nob.h on GitHub
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/tsoding-nob-h.svg)](https://hysenlabs.com/projects/tsoding-nob-h)

Star history chart for your README

markdown
[![Star history](https://hysenlabs.com/chart/tsoding-nob-h.svg)](https://hysenlabs.com/projects/tsoding-nob-h)

Was this useful?