Installing an ad network’s JavaScript code in WordPress is usually straightforward. The risky part is installing it twice, copying credentials from another site, or assuming that a banner rendering means the network has accepted the impression. This guide shows a careful, reversible workflow for integrating a domain-specific ShowMeYours snippet without editing WordPress core files.
Before you paste anything
Use an account you control. Register the exact website domain with ShowMeYours, complete any required activation and copy the JavaScript snippet provided for that website. The site key and activation value are not generic sample text; they belong to the registered site. A snippet issued for one publisher domain should not be reused on a different one.
Write down where your WordPress currently loads scripts. Check whether your active theme or main site plugin already has a header integration field. The goal is exactly one source of truth, not a stack of overlapping injection methods.
Step 1: choose one integration location
The preferred ShowMeYours integration is a centrally supplied JavaScript snippet. If your site already has a maintained global header integration field, use it. If a theme or site plugin provides a specific ad-network integration, follow the documentation for that setting. Do not add a new WordPress plugin merely to paste a few lines when you have an existing supported integration method.
Avoid editing the main theme’s header.php directly. A theme update could overwrite your changes. Likewise, never edit WordPress core files. On a custom WordPress build, a developer can register the verified snippet through the normal wp_head hook, but the precise code should come from the publisher dashboard.
Step 2: paste the code exactly once
Copy the complete snippet from your ShowMeYours site dashboard. Preserve its script source, attributes and site-specific credentials without guessing values. Do not embed someone else’s keys, create a fabricated token or replace the official source with an unofficial mirror.
If your site already has an old ShowMeYours integration, remove the obsolete duplicate before activating the newer one. Two snippets can lead to multiple requests, layout collisions and confusing analytics.
Step 3: configure supported ad positions
Plan layouts that can accommodate the network’s formats: 300 × 250, 728 × 90 and 320 × 100. Use the central code and placement behavior supported by the current service. Do not try to generate qualifying impressions by hiding units offscreen, stacking ads behind other elements or requesting multiple unseen variants.
For layout ideas, see the three supported banner dimensions and our ad placement guide.
Step 4: clear caches, then test like a visitor
- Save the integration in WordPress.
- Clear the relevant page or plugin cache.
- If you use Cloudflare or another CDN, ensure your HTML changes have propagated.
- Open a public desktop page in a private browsing window.
- Repeat with a narrow mobile viewport.
- Inspect browser developer tools for failed script requests, JavaScript exceptions and layout overflow.
A browser ad blocker may prevent the request from loading; that is not proof of a broken integration. Test both with normal privacy settings and, where permissible, in a clean browser session without blocking extensions.
Step 5: confirm publisher statistics
Seeing a banner is the first visual check, not the last validation step. The ShowMeYours member dashboard should show accepted impressions after the system processes eligible activity. You should distinguish requests, successful renders and valid impressions. The public publisher view intentionally focuses on valid activity; rejected and invalid diagnostics belong to the network’s internal administration.
If results are unexpected, check domain registration, exact code, duplicate scripts and browser conditions before making further changes. Don’t modify your main website repeatedly when the fault may be a registration mismatch.
Common failures and safe fixes
| Symptom | Likely thing to check | Action |
|---|---|---|
| Nothing loads | Script blocked, invalid URL or site not activated | Check network requests and assigned code |
| Banner appears twice | Duplicate insertion | Keep one supported integration path |
| Desktop works, mobile overflows | Fixed-width placement | Use intended mobile layout and 320 × 100 format |
| Banner visible but no accepted credits | Validation or site identity mismatch | Review valid statistics; confirm domain and site key |
| Cache shows old code | Stale HTML or optimization cache | Purge the relevant layer, then retest |
How to remove or update it later
Keep a short installation record: which setting contains the code, which registered site it belongs to, when it was updated and where current statistics are visible. When the network provides a new script, replace the old integration rather than stacking snippets. Verify that the ad integration is still compatible with your caching and CSP policies.
Frequently asked questions
Do I need a special ShowMeYours WordPress plugin?
No. The primary integration is JavaScript. Use an existing supported header integration mechanism if one is available.
Can I test using a demo key from another site?
No. Use your own registered domain’s exact credentials.
Will ads always appear immediately?
No. A network may have availability, policy, validation or caching conditions. Confirm behavior in your own publisher dashboard.
Next: understand what counts as an impression before evaluating your credit balance.