# google-maps-reviews

> Display Google Reviews of a Place on Google Maps on your website

Latest version **0.3.1** (published 2025-02-07) · ISC license · 0 weekly downloads

## Install

```sh
npm install google-maps-reviews
pnpm add google-maps-reviews
yarn add google-maps-reviews
bun add google-maps-reviews
```

## Health

**Score 25/100 (F)** — status: maintenance-mode.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: stale; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.3.1 |
| Published | 2025-02-07 |
| First published | 2018-06-12 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 12.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Simon Neutert |
| Maintainers | simonneutert |
| Keywords | google, maps, maps, places, reviews, html5 |

## Links

- npm: https://www.npmjs.com/package/google-maps-reviews
- Repository: https://github.com/simonneutert/google-maps-reviews
- Homepage: https://github.com/simonneutert/google-maps-reviews#readme
- Issues: https://github.com/simonneutert/google-maps-reviews/issues
- npm.io page: https://npm.io/package/google-maps-reviews

## Alternatives

- [@opentelemetry/exporter-zipkin](https://npm.io/package/@opentelemetry/exporter-zipkin.md) — 14.8M weekly downloads
- [pusher-js](https://npm.io/package/pusher-js.md) — 2.0M weekly downloads
- [browserify](https://npm.io/package/browserify.md) — 1.7M weekly downloads
- [sqs-consumer](https://npm.io/package/sqs-consumer.md) — 1.7M weekly downloads
- [@sanity/eventsource](https://npm.io/package/@sanity/eventsource.md) — 930.8K weekly downloads

## Recent versions

- 0.3.1 (latest) — 2025-02-07
- 0.3.0 — 2022-06-25
- 0.2.0 — 2022-02-08
- 0.1.1 — 2020-10-11
- 0.1.0 — 2020-02-11
- 0.0.23 — 2020-01-28
- 0.0.22 — 2019-07-13
- 0.0.21 — 2019-07-11
- 0.0.20 — 2018-09-04
- 0.0.17 — 2018-08-04
- 0.0.16 — 2018-08-04
- 0.0.15 — 2018-08-04
- 0.0.10 — 2018-06-12
- 0.0.1 — 2018-06-12

## README

# Display Google Reviews of a Place on Google Maps on your website

project on npm: https://www.npmjs.com/package/google-maps-reviews

jQuery Version here: https://github.com/simonneutert/jquery-google-reviews

---

> [!IMPORTANT]
> This project is unmaintained and archived.  
> Nevertheless, it remains a valuable guide for those who need to implement a similar solution in their projects.

---

## Credits

Inspired by Steven Monson's magnificent article here:
https://www.launch2success.com/guide/display-google-reviews-website-2017/ or
check out [Steven's github](https://github.com/stevenmonson/googleReviews).
Steven's code is based on
[peledies jquery plugin repo](https://github.com/peledies/google-places). So, I
simply remixed their work into this repo. _Thank you guys!_

#### Dear beginners and copy-pasters

:octocat: _For those of you, who are new in programming or can only copy-paste,
please make sure, that the Google Maps API and the .js-file of this plugin are
successfully loaded before you call this script in the body your html page._

_under demo/index.html is a working demo, the comments will guide you :wink:_

## Prerequisites

**either**

- add the .js and .css of this repo to your project (see index.html for
  inspiration :wink:)

**or**

- `$ npm install -i google-maps-reviews`

**then**

- **if you do not have a working Google Maps API key already:** create a Google
  API Key:
  [https://console.developers.google.com/apis/](https://console.developers.google.com/apis/)

- add the following line with your Google Maps API key with the key param:

  ```html
  <script
    src="https://maps.googleapis.com/maps/api/js?v=3.exp&libraries=places&key=YourApiKeyHere"
  ></script>
  ```

- add an empty **_div_** element in your html's body with an unique ID, where
  the reviews should show up. In this case:

  `<div id="google-reviews"></div>`

## Call the Plugin

[Grab your place's ID (https://developers.google.com/places/place-id) and call it as **_placeId_** parameter, when calling the plugin.](https://developers.google.com/places/place-id)

```html
<!-- add this before </body> -->
<script>
    // Find a placeID via https://developers.google.com/places/place-id
    googlePlaces("google-reviews", {
      placeId: 'ChIJZa6ezJa8j4AR1p1nTSaRtuQ',
      // the following params are optional (default values)
      header: "<h3>Google Reviews</h3>", // html/text over Reviews
      footer: '', // html/text under Reviews block
      maxRows: 6, // max rows of reviews to be displayed
      minRating: 4, // minimum rating of reviews to be displayed
      months: ["Jan", "Feb", "Mär", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dez"],
      textBreakLength: "90", // length before a review box is set to max width
      showDate: false, // renders the date of the review before the review itself
      shortenNames: true, // example: "Max Mustermann" -> "Max M.""
      replaceAnonymous: false, // do not replace anonymous author_name from JSON
      anonymousName: "A Google User", // Google's default value depending on language used (en: "A Google User")
      anonymousNameReplacement: "User chose to remain anonymous", // replacement for default (never shortens)
    });
  });
</script>
```

## Are Pull Requests welcome?

Yes, of course :octocat:

---
_Source: https://npm.io/package/google-maps-reviews · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
