ProRank SEO

Nearest Locations

Add factual local content and real distances to matching landing pages without a remote request during rendering

Pro+ Required. Open ProRank SEO → Local SEO → Nearest Locations. The feature is disabled by default.

What It Does

Nearest Locations matches a landing page's slug, resolves the named place in the background, and appends the closest active locations with real straight-line distances. The HTML is rendered on the server, so search engines and page caches receive stable page-specific content.

Page rendering reads saved WordPress data only. It never waits for postcodes.io or another geocoder.

Configure Page Rules

  1. Enable Add nearest locations to matching pages.
  2. Click Add Rule.
  3. Enter one safe wildcard pattern and the post types it can match.
  4. Choose distance units, an optional venue label, and optional CTA text and URL.
  5. Save settings, then click Run Geocoding.
service-in-*     matches service-in-walsall
branch-*         matches branch-birmingham

Patterns accept lowercase letters, numbers, hyphens, and at most one *. Raw regular expressions are not accepted.

Background Geocoding

The default postcodes_io provider resolves Great Britain place names in bounded background batches. Successful results and confirmed misses are cached; transport errors are retried after backoff.

Use Retry Misses after correcting a rule or changing provider. Use Clear Cache only when all resolved places need rebuilding.

postcodes.io covers Great Britain. Other regions need a provider registered through prorank_nearest_locations_geocoder or manual per-post coordinates.

Optional Device Location

Enable Offer a "Use my location" button to add a progressive enhancement for visitors. The search-engine-facing block remains unchanged.

  • The browser asks for permission only after the visitor clicks.
  • The visitor's coordinates never leave the browser.
  • Distance calculations use the public coordinates of your active locations.
  • Denied, timeout, unavailable, and unsupported states are announced accessibly.

WP-CLI

wp prorank nearest status
wp prorank nearest geocode --limit=100
wp prorank nearest set-place 123 --lat=52.5862 --lon=-2.1288 --name='Wolverhampton'
wp prorank nearest flush-cache --misses-only

Troubleshooting

  • No block appears: confirm the feature is enabled, the post type and slug match a rule, and at least one active location has valid coordinates.
  • A place remains unresolved: check the status counters, then retry misses or provide manual coordinates.
  • Wrong place selected: clear the affected cache entry and use manual coordinates when a name is genuinely ambiguous.
  • Device button is absent: enable the device-location toggle and clear page/CDN caches.