$AdSenseSim
v3.0.0 — Stable Release

AdSense Simulator

Simulate Google AdSense behavior for development and testing. Test ad placements, responsive layouts, and SPA integration — entirely in the browser, zero network requests.

adsense-simulator: started
adsense-simulator: started { removeGoogleAds: "true" }
adsense-simulator: blocked Google AdSense script
[slot] ca-pub-demo / 123456 300×250 fixed ✓
[slot] ca-pub-demo / 789012 728×90 auto ✓
[slot] ca-pub-demo / 345678 160×600 fixed ✓

// features

Everything you need to test ads

Built to mirror the real AdSense runtime so you can develop without a live account or internet access.

Scan Slots

Automatically detect all <ins> tags on your page. Validates data attributes and dimensions in real-time.

Watch Navigation

Full support for SPA frameworks — React, Vue, Next.js. Re-triggers simulations on every client-side route change automatically.

Simulate Fills

Test "No Fill" scenarios, slow network loading, and dynamic resizing. Visualizes the exact footprint of each ad slot.

// install

Ready to simulate your ad placements?

Install via npm or drop in the CDN script. Works with any framework — no AdSense account required.

$npm install @codepenguin/adsense-simulator
// then import in your dev entry point
import "@codepenguin/adsense-simulator";

MIT License — no AdSense account or network access required