Nim VS zig

Compare Nim vs zig and see what are their differences.

Nim

Nim is a statically typed compiled systems programming language. It combines successful concepts from mature languages like Python, Ada and Modula. Its design focuses on efficiency, expressiveness, and elegance (in that order of priority). (by nim-lang)

zig

General-purpose programming language and toolchain for maintaining robust, optimal, and reusable software. (by ziglang)
CodeRabbit: AI Code Reviews for Developers
Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.
coderabbit.ai
featured
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com
featured
Nim zig
356 869
16,895 37,954
0.7% 2.7%
9.9 10.0
about 23 hours ago 6 days ago
Nim Zig
GNU General Public License v3.0 or later MIT License
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.

Nim

Posts with mentions or reviews of Nim. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2025-01-07.

zig

Posts with mentions or reviews of zig. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2025-03-05.
  • Zig: A good memory allocator in 200 lines of code
    1 project | news.ycombinator.com | 6 Mar 2025
  • A good memory allocator in 200 lines of code
    1 project | news.ycombinator.com | 5 Mar 2025
  • Zig-0.14.0 Landed
    3 projects | news.ycombinator.com | 5 Mar 2025
    One thing I'm super excited about here is that Zig can now cross-compile CGO to macOS [0], granted you link the appropriate macOS frameworks and SDK [1].

    [0]: https://github.com/ziglang/zig/issues/20689, https://github.com/ziglang/zig/issues/21721

    [1]: https://github.com/tpoechtrager/osxcross

  • Hallucinations in code are the least dangerous form of LLM mistakes
    1 project | news.ycombinator.com | 2 Mar 2025
    > Chose boring technology. I genuinely find myself picking libraries that have been around for a while partly because that way it’s much more likely that LLMs will be able to use them.

    This is an appeal against innovation.

    > I’ll finish this rant with a related observation: I keep seeing people say “if I have to review every line of code an LLM writes, it would have been faster to write it myself!”

    > Those people are loudly declaring that they have under-invested in the crucial skills of reading, understanding and reviewing code written by other people. I suggest getting some more practice in. Reviewing code written for you by LLMs is a great way to do that.

    As someone who has spent [an incredible amount of time reviewing other people's code](https://github.com/ziglang/zig/pulls?q=is%3Apr+is%3Aclosed), my perspective is that reviewing code is fundamentally slower than writing it oneself. The purpose of reviewing code is mentorship, investing in the community, and building trust, so that those reviewees can become autonomous and eventually help out with reviewing.

    You get none of that from reviewing code generated by an LLM.

  • F8 – an 8 bit architecture designed for C and memory efficiency [video]
    2 projects | news.ycombinator.com | 20 Feb 2025
  • Rust Kernel Policy
    3 projects | news.ycombinator.com | 11 Feb 2025
    But the situation for Rust-C++ interop is also worse than for Rust-C interop. Why else would Google spend maybe $1 million on improving it in 2024? https://www.theregister.com/2024/02/05/google_rust_donation/ Many years after Rust got support in Mozilla for usage with Firefox written in C++.

    >My sibling is also correct, language decisions were made in order to keep FFI zero overhead.

    Yet overhead is only one piece of the puzzle for FFI and interop with C, or for that matter, C++.

    How does Rust compare with a language with less advanced and more simple semantics and requirements of invariants, like Zig?

    https://ziglang.org/

    >Incrementally improve your C/C++/Zig codebase.

  • A tale of several distros joining forces for a common goal: reproducible builds
    9 projects | news.ycombinator.com | 8 Feb 2025
    Regarding the reproducible bootstrapping problem, what is your project's policy on building from binary sources? For instance, Zig is written in zig and bootstraps from a binary wasm file which is translated to C: https://github.com/ziglang/zig/tree/master/stage1

    Golang has an even more complicated bootstrapping procedure requiring to build each successive version of the compiler to get to the most recent version.

  • Zig Guide
    2 projects | news.ycombinator.com | 5 Feb 2025
    I love Zig and I love that it’s getting attention, but can someone convince me of its memory safety? One thing that surprised me is that returning pointers to stack-allocated memory doesn’t cause a compiler error — it just segfaults at runtime. This has been an open issue since 2019 [#2646](https://github.com/ziglang/zig/issues/2646).

    That, along with the number of memory-related issues in one of Zig’s most popular project, Bun.js [search: segfault](https://github.com/oven-sh/bun/issues?q=is%3Aissue+segfault), gives me pause.

  • Zig; what I think after months of using it
    6 projects | news.ycombinator.com | 4 Feb 2025
    The duck typing argument is absolutely not based on minimal or missing documentation. There wouldn't be countless issues about it in the Zig repository if it were that simple. See https://github.com/ziglang/zig/issues/17198

    I'm simply going to quote one of the comments from the linked GitHub issue:

    > generic code is hard. Hard to implement correctly, hard to test, hard to use, hard to reason about. But, for better or worse, Zig has generics. That is something that cannot be ignored. The presence of generic capabilities means that generic code will be written; most of the std relies on generic code.

  • In Zig, What's a Writer?
    5 projects | news.ycombinator.com | 1 Feb 2025
    `appendSliceOptimized` is implemented using knowledge of the underlying writer, the way that say an interface implementation in Go would be able to. It's a big part of the reason that reading a file in Zig line-by-line can be so much slower than in other languages (2)

    (1) https://gist.github.com/karlseguin/1d189f683797b0ee00cdb8186...

    (2) https://github.com/ziglang/zig/issues/17985

What are some alternatives?

When comparing Nim and zig you can also consider the following projects:

Odin - Odin Programming Language

v - Simple, fast, safe, compiled language for developing maintainable software. Compiles itself in <1s with zero library dependencies. Supports automatic C => V translation. https://vlang.io

ssr-proxy-js - A Server-Side Rendering Proxy focused on customization and flexibility!

go - The Go programming language

CodeRabbit: AI Code Reviews for Developers
Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.
coderabbit.ai
featured
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com
featured

Did you know that Nim is
the 47th most popular programming language
based on number of references?