Register a Disqus account and create a Site
- Go to disqus.com
- Click the
Sign up
button in the top-right corner and selectPublishers
- Create a New Site; the category can be anything
- On the
Select Your Website Platform
step, scroll to the bottom and clickI don't see my platform listed, install manually with Universal Code
. Then you can skip the installation steps for now — you’ll still be able to change the platform and view the installation instructions later - Copy the
Shortname
; you will paste this value into Hugo’sconfig.yml
later
Enable Comments in PaperMod
For related feature settings, refer to PaperMod’s exampleSite and the Hugo comments documentation.
- Add the following settings to your Hugo
config.yml
# Enable comments feature
params:
comments: true
# Set Disqus Shortname
services:
disqus:
shortname: "<your Disqus shortname here>"
Replace <your Disqus shortname here>
with the shortname you copied from Disqus.
- Since Hugo comes with a built-in Disqus template, you can simply add the following content to
layouts/partials/comments.html
:- if the directory or file doesn’t exist, create it manually
- if you need to override Hugo’s built-in template, refer to the official documentation
{{ partial "disqus.html" . }}