
外掛標籤
開發者團隊
② 後台搜尋「GeoShield – Country Restrictions Lite for WooCommerce」→ 直接安裝(推薦)
原文外掛簡介
GeoShield Lite is a geolocation-based product restriction plugin for WooCommerce. It gives store owners control over which products are visible or purchasable based on a visitor’s country.
This is useful for stores that need to comply with international licensing agreements, regional distribution contracts, or country-specific product availability rules.
How It Works
GeoShield Lite primarily uses the built-in WooCommerce geolocation system (MaxMind GeoIP database) to detect a visitor’s country. To ensure a seamless “out-of-the-box” experience for stores without a MaxMind configuration, the plugin includes a fail-safe fallback to a legitimate third-party geolocation service. Based on per-product restriction rules you configure, the plugin can either hide products entirely or disable the purchase button for visitors from specified countries.
All restriction logic runs locally using WordPress metadata — external API calls are used strictly as a fallback for country identification when local detection is unavailable.
Features
Per-Product Restrictions — Define unique country restriction rules directly within the WooCommerce product editor.
Variation-Level Overrides — Apply independent geographic rules to specific product variations.
Blacklist and Whitelist Modes — Block selected countries (blacklist) or allow only selected countries (whitelist).
Two Restriction Actions — Hide the product completely from the catalog, or keep it visible but disable the purchase button.
Custom Restriction Messages — Display a configurable message to visitors who are restricted from purchasing.
Automatic Catalog Filtering — Restricted products are automatically filtered from the shop page, category pages, search results, and related product sections.
WooCommerce Blocks Compatibility — Works with both classic and block-based Cart and Checkout pages.
HPOS Compatible — Fully compatible with WooCommerce High-Performance Order Storage.
Configuration
After activation, configure restrictions on individual products:
Edit any WooCommerce product.
Open the Country Restrictions tab in the Product Data panel.
Enable restrictions and select your target countries.
Choose between Hide Product or Disable Purchase.
Save the product.
Global settings are available under the GeoShield > Settings menu.
External Services
GeoShield Lite uses external services to detect visitor locations for restriction purposes. Below is complete documentation of all external services used, what data is transmitted, and when.
IP Address Detection Service (ipify)
What it does: Detects your server’s public IP address to enable accurate geolocation when your server is behind a proxy, load balancer, or CDN.
When it’s used: Only when the plugin needs to determine the server’s external IP address for geolocation purposes. This typically happens once during initial setup or when geolocation cache expires.
What data is sent: A standard HTTP request to api.ipify.org. No user data, no store data, no personal information is transmitted. Only your server’s IP address is detected (which is already visible to any website you connect to).
Service provider: ipify API
Website: https://www.ipify.org
Terms of Service: https://www.ipify.org
Privacy Policy: https://www.ipify.org (ipify does not log or store IP addresses)
Geolocation Service (IP-API)
What it does: Converts IP addresses to geographic locations (country and state/region) to enforce your restriction rules.
When it’s used: As a fallback when WooCommerce’s built-in geolocation is unavailable. Only activates if you haven’t configured MaxMind GeoIP in WooCommerce settings.
What data is sent: The visitor’s IP address is sent to ip-api.com to determine their country and state/region. No other personal information is transmitted.
Service provider: IP-API
Website: https://ip-api.com
Terms of Service: https://ip-api.com/docs/legal
Privacy Policy: https://ip-api.com/docs/legal
Note: You can avoid using this fallback service by configuring MaxMind GeoIP in WooCommerce → Settings → Integration. When MaxMind is configured, GeoShield uses WooCommerce’s native geolocation exclusively.
Data Privacy & GDPR Compliance
GeoShield is designed with privacy in mind:
Only IP addresses are transmitted to external services (no names, emails, or personal data)
IP addresses are processed solely for geolocation purposes
No data is stored by external services (per their privacy policies)
All external calls use secure HTTPS connections
You can use WooCommerce’s built-in MaxMind integration to eliminate fallback external calls entirely
If you have privacy concerns, we recommend configuring MaxMind GeoIP in WooCommerce settings to keep all geolocation processing local to your server.
