Developer Guide & Integration Hub

Embeddable Review Widgets & API

Turn verified CompanyRank ratings into instant conversion boosters. Integrate our lightweight JavaScript loader, responsive iframe embeds, or query our REST API directly.

3-Minute Setup

Quickstart Integration

Embed verified reviews in any web page by copying two lines of HTML. No build tools or third-party dependencies required.

Drop-in HTML Snippet
<!-- CompanyRank Review Widget -->
<div 
  class="cr-widget"
  data-domain="yourcompany.co.uk"
  data-type="carousel"
  data-theme="dark-emerald"
  data-stars="4-5"
  data-accent="trust-green">
</div>
<script async src="https://companyrank.co.uk/widget.js"></script>
1

Place Container

Paste the <div class="cr-widget"> tag where you want reviews displayed on your page.

2

Include Loader

Add widget.js once on the page. It executes asynchronously and adds less than 2.5 KB to page weight.

3

Automatic Resizing

The widget measures its content height and seamlessly resizes with zero scrollbars or layout shift.

Interactive Showcase

Explore the 5 Widget Shapes

Choose the right format for every stage of your customer funnel. Test live responsive interactions below.

Platform Guides

CMS & Framework Integration

Step-by-step instructions for embedding widgets in your specific website builder or framework.

Vanilla HTML & Static Sites

Add the container tag inside your HTML body, then load widget.js once before the closing </body> tag:

<!-- CompanyRank Review Widget -->
<div 
  class="cr-widget"
  data-domain="yourcompany.co.uk"
  data-type="carousel"
  data-theme="dark-emerald"
  data-stars="4-5"
  data-accent="trust-green">
</div>
<script async src="https://companyrank.co.uk/widget.js"></script>
Configuration

Attributes & Parameters Reference

Every attribute supported by .cr-widget and the /embed URL parameters.

HTML AttributeURL Query ParamAllowed ValuesDefaultDescription
data-domaindomainDomain string (e.g. refundee.com)RequiredThe verified company domain in the directory.
data-typetypecarousel, badge, pill, grid, collectorcarouselVisual shape and layout of the widget.
data-themethemedark-emerald, dark-navy, light, transparentdark-emeraldSurface color and border contrast theme.
data-accentaccenttrust-green, companyrank-teal, goldtrust-greenStar rating and verified badge accent color.
data-starsstars4-5, 5, all4-5Filter reviews by star rating.
data-headlineheadlinetrue, falsetrueShows or hides the top headline row on Carousels and Grids.
data-titletitleCustom stringRated [Score] on CompanyRank.Custom headline title text override.
data-taglinetaglineCustom stringDynamic count summaryCustom supporting tagline text override.
data-position—bottom-right, bottom-leftInlineFor pill widgets: fixes the badge to the corner of the screen.
Developer API

REST API Reference

Fetch pre-computed review stats, verified trust ratings, and pre-formatted embed codes directly via HTTP.

GET/api/widgets?domain={domain}

Returns real-time company review metrics, top verified quotes, and pre-formatted embed codes. Includes CORS headers (Access-Control-Allow-Origin: *) and global Edge CDN caching (Cache-Control: public, s-maxage=1800).

Sample cURL Request

curl -X GET "https://companyrank.co.uk/api/widgets?domain=refundee.com&type=carousel" \ -H "Accept: application/json"

JSON Response Payload (200 OK)

{
  "status": "success",
  "domain": "refundee.com",
  "company": {
    "name": "Refundee",
    "displayName": "Refundee Ltd",
    "domain": "refundee.com",
    "websiteUrl": "https://refundee.com",
    "categoryId": "money-insurance",
    "categoryName": "Money & Insurance",
    "rating": 4.8,
    "reviewCount": 801,
    "scoreDescriptor": "Excellent",
    "profileUrl": "https://companyrank.co.uk/companies/refundee.com",
    "verified": true
  },
  "config": {
    "type": "carousel",
    "theme": "dark-emerald",
    "stars": "4-5",
    "accent": "trust-green",
    "headline": true
  },
  "embed": {
    "script": "<div class=\"cr-widget\" data-domain=\"refundee.com\" ...></div>\n<script async src=\"https://companyrank.co.uk/widget.js\"></script>",
    "iframe": "<iframe src=\"https://companyrank.co.uk/embed?domain=refundee.com&type=carousel...\" ...></iframe>",
    "url": "https://companyrank.co.uk/embed?domain=refundee.com&type=carousel&theme=dark-emerald",
    "widgetScriptUrl": "https://companyrank.co.uk/widget.js"
  },
  "reviews": [
    {
      "id": "rev-1",
      "author": "SkiPaul",
      "rating": 5,
      "title": "Can't recommend Refundee highly enough",
      "body": "Refundee were thoroughly professional...",
      "publishedAt": "2026-10-06T12:00:00.000Z"
    }
  ]
}