Basic Widget Setup

The SimpleCommenter widget is a lightweight JavaScript snippet that adds a feedback button to your website. This guide covers the fundamental setup process.

How It Works

  1. You add our script to your website
  2. The script loads asynchronously (won't slow down your page)
  3. A feedback button appears for your visitors
  4. Visitors can submit feedback, which appears in your dashboard

Adding the Widget

Add this script tag to your website's HTML, just before the </body> tag:

<script
  src="https://simplecommenter.com/js/comments.min.js"
  data-domain="your-domain.com"
  defer
></script>

The defer attribute ensures the script loads without blocking your page render.

Required Setup

1. Register Your Domain

Before the widget works, you must register your domain in the SimpleCommenter dashboard:

  1. Go to your dashboard
  2. Click "Add Project"
  3. Enter your domain exactly as visitors will see it
  4. Save the project

2. Match the Domain

The data-domain attribute must match your registered domain:

<!-- If you registered "example.com" -->
<script
  src="https://simplecommenter.com/js/comments.min.js"
  data-domain="example.com"
  defer
></script>

<!-- If you registered "www.example.com" -->
<script
  src="https://simplecommenter.com/js/comments.min.js"
  data-domain="www.example.com"
  defer
></script>

Testing Locally

For local development, you can test with localhost:

<script
  src="https://simplecommenter.com/js/comments.min.js"
  data-domain="localhost:3000"
  defer
></script>

Make sure to register localhost:3000 (or your local port) as a domain in your dashboard for testing.

What Visitors See

When the widget loads, visitors will see:

  1. Feedback Button - A small button in the corner of the screen
  2. Feedback Form - Opens when clicked, with fields for:
    • Comment text
    • Screenshot capture (optional)
    • Email (optional)
  3. Confirmation - Success message after submission

Next Steps

Was this page helpful?