README.md

September 7, 2026 ยท View on GitHub


Logo

go-grip

Render your markdown files local
- with the look of GitHub

Table of Contents

:question: About

go-grip is a lightweight, Go-based tool designed to render Markdown files locally, replicating GitHub's style. It offers features like syntax highlighting, dark mode, and support for mermaid diagrams, providing a seamless and visually consistent way to preview Markdown files in your browser.

This project is a reimplementation of the original Python-based grip, which uses GitHub's web API for rendering. By eliminating the reliance on external APIs, go-grip delivers similar functionality while being fully self-contained, faster, and more secure - perfect for offline use or privacy-conscious users.

:zap: Features

  • :zap: Written in Go :+1:
  • ๐Ÿ“„ Render markdown to HTML and view it in your browser
  • ๐Ÿ“ฑ Dark and light theme
  • ๐ŸŽจ Syntax highlighting for code
  • Todo list like the one on GitHub
  • Support for github markdown emojis :+1:
  • Support for mermaid diagrams
  • hashtag linking in page (see table of contents)
  • math expressions (code, inline, block)
  • gh issues and prs #46 and grafana/grafana#22
  • toggle state is preserved in sessionStorage

This is an inline 3xโˆ’1+(1+x)2\sqrt{3x-1}+(1+x)^2 function.

(โˆ‘k=1nakbk)2โ‰ค(โˆ‘k=1nak2)(โˆ‘k=1nbk2)\left( \sum_{k=1}^n a_k b_k \right)^2 \leq \left( \sum_{k=1}^n a_k^2 \right) \left( \sum_{k=1}^n b_k^2 \right)

(โˆ‘k=1nakbk)2โ‰ค(โˆ‘k=1nak2)(โˆ‘k=1nbk2)\left( \sum_{k=1}^n a_k b_k \right)^2 \leq \left( \sum_{k=1}^n a_k^2 \right) \left( \sum_{k=1}^n b_k^2 \right)
graph TD;
    A-->B;
    A-->C;
    B-->D;
    C-->D;
package main

import "github.com/chrishrb/go-grip/cmd"

func main() {
	fmt.Sprintln("Welcome to Grip! Use `go-grip --help` for more information.")
}

Tip

Support of blockquotes (note, tip, important, warning and caution) see here

Important

test

:rocket: Getting started

To install go-grip, simply:

go install github.com/chrishrb/go-grip@latest

Tip

You can also use nix flakes to install this plugin. More useful information here.

:hammer: Usage

To render the README.md file simply execute:

go-grip README.md
# or
go-grip

The browser will automatically open on http://localhost:6419. You can disable this behaviour with the -b=false option.

You can also specify a port:

go-grip -p 80 README.md

or just open a file-tree with all available files in the current directory:

go-grip

If a README.md exists in that directory it is opened directly, otherwise the file-tree is shown. You can also browse the tree at any time on http://localhost:6419.

Dark mode is not a launch option: use the toggle in the top right corner of the page. Your choice is stored in the browser's local storage, so each browser remembers its own theme. Without a stored choice the page follows the operating system's prefers-color-scheme setting.

To disable automatic browser reload on file changes (useful for stable editing):

go-grip --no-reload README.md

The browser page title is derived from the Markdown filename (my-guide_v2.md becomes My Guide V2).

To check which build you are running:

go-grip --version

To terminate the current server simply press CTRL-C.

:pencil: Examples

examples

:bug: Known TODOs / Bugs

  • Make it possible to export the generated html

:pushpin: Similar tools

This tool is a Go-based reimplementation of the original grip, offering the same functionality without relying on GitHub's web API.