# Announcing Jetzig (web framework) and Zmpl (templating language) for Zig

**URL:** <https://ziggit.dev/t/announcing-jetzig-web-framework-and-zmpl-templating-language-for-zig/2958>\
**Category:** Showcase\
**Tags:** ecosystem\
**Created:** [January 21, 2024, 10:28pm UTC](https://ziggit.dev/t/announcing-jetzig-web-framework-and-zmpl-templating-language-for-zig/2958 "2024-01-21T22:28:05Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![bobf](https://ziggit.dev/letter_avatar_proxy/v4/letter/b/ad7895/32.png) [@bobf](https://ziggit.dev/u/bobf)\
**Post date:** [January 21, 2024, 10:28pm UTC](https://ziggit.dev/t/announcing-jetzig-web-framework-and-zmpl-templating-language-for-zig/2958/1 "2024-01-21T22:28:05Z")

</div>

Here are some links if you want to skip reading the text below:

- [Project Homepage](https://www.jetzig.dev) (docs are basic but will expand soon)
- [GitHub project group](https://github.com/jetzig-framework/)

I have been working on a “batteries-included” web framework for Zig for a couple of months in my spare time. The project has been coming along quite well and already has some pretty nice features, including a Templ-like (kind of) templating language called Zmpl, dynamic JSON/template data object building, structured encrypted user session cookies, static content rendering, file-based routing and template discovery, etc.

It has a long way to go before being production ready but it is now possible to create “real” web applications with it. I am using it with HTMX and I am finding Zig a very nice language to use for web dev (I come from a Python/Ruby background).

I have a long list of features I plan to add to the framework and it is winter here so I am not going outside much. 🙂

Hope you are all having a nice weekend.

---

<div class="post-metadata">

**Author:** ![dude\_the\_builder](https://ziggit.dev/user_avatar/ziggit.dev/dude_the_builder/32/557_2.png) [@dude\_the\_builder](https://ziggit.dev/u/dude_the_builder)\
**Post date:** [January 21, 2024, 10:39pm UTC](https://ziggit.dev/t/announcing-jetzig-web-framework-and-zmpl-templating-language-for-zig/2958/2 "2024-01-21T22:39:42Z")

</div>

Haven’t looked at the code or tried it, but had to say: That logo ROCKS!

---

<div class="post-metadata">

**Author:** ![bobf](https://ziggit.dev/letter_avatar_proxy/v4/letter/b/ad7895/32.png) [@bobf](https://ziggit.dev/u/bobf)\
**Post date:** [January 21, 2024, 11:09pm UTC](https://ziggit.dev/t/announcing-jetzig-web-framework-and-zmpl-templating-language-for-zig/2958/3 "2024-01-21T23:09:35Z")

</div>

Haha, yeah I just got it today, I’ll add a link to the designer’s fiverr to the website.

Thank you so much for your videos, I watch all of them and have learned so much, I’ve been planning to make a donation to your channel soon !

---

<div class="post-metadata">

**Author:** ![z1fire](https://ziggit.dev/user_avatar/ziggit.dev/z1fire/32/742_2.png) [@z1fire](https://ziggit.dev/u/z1fire)\
**Post date:** [January 22, 2024, 1:21am UTC](https://ziggit.dev/t/announcing-jetzig-web-framework-and-zmpl-templating-language-for-zig/2958/4 "2024-01-22T01:21:41Z")

</div>

would you use the zmpl file extension instead of an html one?

---

<div class="post-metadata">

**Author:** ![Cloudef](https://ziggit.dev/user_avatar/ziggit.dev/cloudef/32/1370_2.png) [@Cloudef](https://ziggit.dev/u/Cloudef)\
**Post date:** [January 22, 2024, 8:39am UTC](https://ziggit.dev/t/announcing-jetzig-web-framework-and-zmpl-templating-language-for-zig/2958/5 "2024-01-22T08:39:23Z")

</div>

You might be interested in dependency injection and automatic body/path/query de-serialization into structs like I do here [GitHub - Cloudef/zig-router: Straightforward HTTP-like request routing.](https://github.com/Cloudef/zig-router/tree/master)

---

<div class="post-metadata">

**Author:** ![bobf](https://ziggit.dev/letter_avatar_proxy/v4/letter/b/ad7895/32.png) [@bobf](https://ziggit.dev/u/bobf)\
**Post date:** [January 22, 2024, 8:44am UTC](https://ziggit.dev/t/announcing-jetzig-web-framework-and-zmpl-templating-language-for-zig/2958/6 "2024-01-22T08:44:21Z")

</div>

Great, I will take a look ! Jetzig routing is very basic at the moment and I am expecting to overhaul it completely (internally), so anything I can learn from your work would be very helpful.

---

<div class="post-metadata">

**Author:** ![bobf](https://ziggit.dev/letter_avatar_proxy/v4/letter/b/ad7895/32.png) [@bobf](https://ziggit.dev/u/bobf)\
**Post date:** [January 22, 2024, 8:45am UTC](https://ziggit.dev/t/announcing-jetzig-web-framework-and-zmpl-templating-language-for-zig/2958/7 "2024-01-22T08:45:25Z")

</div>

I thought about using `.html.zmpl` but I decided to go with `.zmpl` since Zmpl is (primarily) an HTML templating language, so the extra extension seemed redundant.

I’m hoping I can figure out how to get zls integration working but that’s for later.

---

<div class="post-metadata">

**Author:** ![bobf](https://ziggit.dev/letter_avatar_proxy/v4/letter/b/ad7895/32.png) [@bobf](https://ziggit.dev/u/bobf)\
**Post date:** [February 4, 2024, 2:07pm UTC](https://ziggit.dev/t/announcing-jetzig-web-framework-and-zmpl-templating-language-for-zig/2958/8 "2024-02-04T14:07:51Z")

</div>

Hi again, just coming back from illness so apologies for the delay but wanted to let you know I added a link to your project to Jetzig’s GitHub here: [GitHub - jetzig-framework/jetzig: Jetzig is a web framework written in Zig](https://github.com/jetzig-framework/jetzig)

---

<div class="post-metadata">

**Author:** ![JordanShurmer](https://ziggit.dev/user_avatar/ziggit.dev/jordanshurmer/32/2798_2.png) [@JordanShurmer](https://ziggit.dev/u/JordanShurmer)\
**Post date:** [June 24, 2024, 1:29am UTC](https://ziggit.dev/t/announcing-jetzig-web-framework-and-zmpl-templating-language-for-zig/2958/9 "2024-06-24T01:29:18Z")

</div>

This is very cool! I started down the road of doing this recently, but have not put much time into it. I may use this framework instead.

---

<div class="post-metadata">

**Author:** ![Ravin](https://ziggit.dev/user_avatar/ziggit.dev/ravin/32/2792_2.png) [@Ravin](https://ziggit.dev/u/Ravin)\
**Post date:** [June 24, 2024, 2:27am UTC](https://ziggit.dev/t/announcing-jetzig-web-framework-and-zmpl-templating-language-for-zig/2958/10 "2024-06-24T02:27:28Z")

</div>

Are you taking inspiration from any existing web frameworks?

I was going on the same route on doing a web framework also, mostly following laravel convention and structure.

---

<div class="post-metadata">

**Author:** ![bobf](https://ziggit.dev/letter_avatar_proxy/v4/letter/b/ad7895/32.png) [@bobf](https://ziggit.dev/u/bobf)\
**Post date:** [June 24, 2024, 8:43pm UTC](https://ziggit.dev/t/announcing-jetzig-web-framework-and-zmpl-templating-language-for-zig/2958/11 "2024-06-24T20:43:33Z")

</div>

Hi, Ravin. Inspiration comes from all the frameworks I’ve used over the years - Rails, Django, Laravel, Next.js, Phoenix, etc. etc.

I’m planning to add Inertia.js middleware soon as well.

If you are interested in contributing to the project, please feel free to join our Discord (see [https://jetzig.dev/](https://jetzig.dev/) for details) or, if you are building your own project, let me know and I will add a link to it on the website/README.
