Skip to content



Library that brings frontend-like components experience to the server side with native html/template on steroids. Supports any serving basis (net/http/gin/etc), that provides io.Writer in response.

License Go Report Card Go Reference

This project in early development, don't use in production! In case of any issues/proposals, feel free to open an issue

Why I need this?

  • Get rid of spaghetti inside of handlers
  • Organize code into configurable components structure
  • Simple and straightforward page rendering lifecycle
  • Asynchronous DTO without goroutine mess
  • Built-in dynamics like Hotwire or Laravel Livewire
  • Everyting on top of well-known html/template
  • Get control over project setup: 0 external dependencies, just kyoto itself

Why not?

  • In active development (not production ready)
  • Not situable for pretty dynamic frontends
  • You want to develop SPA/PWA
  • You're just feeling OK with JS frameworks


As simple as go get
Check documentation page for quick start:


Kyoto project setup may seem complicated and unusual at first sight.
It's highly recommended to follow documentation while using library:

This example is not completely independent and just shows what the code looks like when using kyoto:

package main

import (


type PageIndex struct {
    Navbar kyoto.Component

func (p *PageIndex) Template() *template.Template {
    return mktemplate("page.index.html")

func (p *PageIndex) Init() {
    p.Navbar = kyoto.RegC(p, &twui.AppUINavNavbar{
        Logo: `<img src="/static/img/kyoto.svg" class="h-8 w-8 scale-150" />`,
        Links: []twui.AppUINavNavbarLink{
            {Text: "Kyoto", Href: ""},
            {Text: "UIKit", Href: ""},
            {Text: "Charts", Href: ""},
            {Text: "Starter", Href: ""},
        Profile: twui.AppUINavNavbarProfile{
            Enabled: true,
            Avatar: `
                    <svg class="w-6 h-6 text-gray-300" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns=""><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M3 8l7.89 5.26a2 2 0 002.22 0L21 8M5 19h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v10a2 2 0 002 2z"></path></svg>
            Links: []twui.AppUINavNavbarLink{
                {Text: "GitHub", Href: ""},
                {Text: "Telegram", Href: ""},
                {Text: "Email", Href: "mailto:[email protected]"},


Demo project, Hacker News client made with kyoto:
Demo project, features overview:


Buy me a Coffee

Or directly with Bitcoin: bc1qgxe4u799f8pdyzk65sqpq28xj0yc6g05ckhvkk

Back to top