You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

3.0 KiB

npq hugo theme



here is a live demo you can see

main features

  • dark
  • responsive
  • out of the box contact form
  • avatar support
  • syntax highlighting
  • table of content
  • customizable


after you have installed hugo (see quick start) run the following in your site's root directory to install the theme

git clone
cp npq-hugo/example-config.toml .


this is how your config.toml will look like after installation, change the values according to your site.

baseURL = ""
languageCode = "en-us"
title = "title"
copyright = "Copyright © 20082019, Steve Francia and the Hugo Authors; all rights reserved."
theme = "npq-hugo"

  author = "your name"
  description = "your description"
  keywords = "hugo blog"
  useAvatar = true
  microBlogSection = "posts"
  displayMicroBlog = true
  displayRecent = true
  recentMax = 4
  mail = ""
  phone = "8888888888"
  formspreeID = "yourformspreeID"

    name = "home"
    pre = "<i class=\"fas fa-home fa-sm\"></i>"
    url = "/"
    weight = -9 
    name = "blog"
    pre = "<i class=\"fas fa-keyboard fa-ms\"></i>"
    url = "/blog/"
    weight = -8
    name = "tags"
    pre = "<i class=\"fas fa-tags fa-ms\"></i>"
    url = "/tags"
    weight = -7 
    name = "github"
    pre = "<i class=\"fab fa-github fa-ms\"></i>"
    url = ""
    weight = -6 
    name = "RSS"
    pre = "<i class=\"fas fa-rss fa-ms\"></i>"
    url = "/index.xml"
    weight = -4 
    name = "contact"
    pre = "<i class=\"far fa-envelope\"></i>"
    url = "/contact"
    weight = -1 

for the contact page to work you have to make a free form at formspree and put your form id in the variable formspreeID in the configuration file.

every menu entry has a corresponding section named [[menu.mail]] under [menu]. to add or change a menu entry add or change the corresponding section with name being the name displayed in the menu, pre is a text before the name (you can grap icons from fontawesome), url is the url that the menu item points to, and weight is an integer value that represent the order of the menu items (items with lower weight float)

In order to see your site updating while changing it, run Hugo's built-in local server.

hugo server

micro blog

posts in the directory "posts" (can be configured) in the contents directory will be displayed under the microblog section on the home page. if you want to pin a post to the top put pinned: true in the post's front matter. example front matter:

pinned: true
date: 2020-04-09T00:16:00+02:00