git2html is a simple git web interface. Unlike other web interfaces, git2html does not generate content dynamically: instead of using a CGI script, it generates static HTML pages. Generating static HTML pages has advantages and disadvantages. The main advantages are that it is more secure and more robust. It is more robust in the sense that web server configuration changes are unlikely to cause the interface to stop working. Its primary disadvantage is that because the pages are generated statically, not all queries can be supported, e.g., diffs between arbitrary revisions. Despite this seemingly dehabilitating disadvantage, the output is surprisingly useful.

You can view git2html in action.


git2html has a few command line arguments. They are:
  $ ./
  Usage ./ [-prlbq] TARGET
  Generate static HTML pages in TARGET for the specified git repository.
    -p  Project's name
    -r  Repository to clone from.
    -l  Public repository link, e.g., ''
    -b  List of branches to process (default: all).
    -q  Be quiet.
    -f  Force rebuilding of all pages.
The first time you run git2html, you need to indicate your project's name (-p), the link for viewers to clone the repository (-l), the repository to get updates from (-r) and the target directory. Here is how I configured git2html's viewer directory:
 $ ./ \
     -p git2html \
     -l \
     -r /home/neal/public_html/git2html.git 
Note that this first run will take a fair amount of time. git2html tries to be smart and avoids doing a fair amount of redundant work on subsequent runs. Subsequent runs only require the target directory (git2html saves the configuration in the target directory in the .ht_git2html file). After commiting to git2html's repository, the following command is run:
 $ ./ ~/public_html/git2html/src/


To get the source:
  git clone


Send bug reports and patches to Neal H. Walfield <neal@walfield>. Some limitations are list in the TODO file.