Prebid Integration Modes
The Sellwild SDK supports three distinct Prebid integration modes. Each mode represents a different trade-off between implementation complexity, latency, and native rendering capability. Publishers can start with Mode A and progressively migrate to Mode B or Mode C as requirements evolve.
Mode A: Prebid.js in WebView (Default)
Mode A runs the standard Prebid.js auction inside a WebView that is embedded within the native ad container. This is the default integration mode and requires no server-side infrastructure.
How it works:
- The SDK creates a lightweight WebView within the ad placement.
- Prebid.js runs inside the WebView, executing the client-side header bidding auction.
- Winning creative HTML is rendered directly in the WebView.
- The native shell handles viewport sizing, visibility tracking, and lifecycle events.
Advantages:
- Zero server infrastructure required.
- Full Prebid.js adapter ecosystem available out of the box.
- Fastest path to integration for publishers already using Prebid.js on web.
Limitations:
- Auction latency is borne by the end user's device.
- WebView rendering can introduce minor visual inconsistencies compared to fully native UI.
- Each ad instance carries the memory overhead of a WebView.
Mode B: Prebid Server S2S
Mode B moves the header bidding auction to a server-side Prebid Server instance. This is the integration mode currently being proposed for partners such as Weatherbug, where latency and device resource consumption are primary concerns.
How it works:
- The SDK sends an OpenRTB bid request to the Sellwild Prebid Server endpoint at
https://prebid.sellwild.com. - Prebid Server executes the auction server-side, calling all configured demand partners in parallel.
- The server returns the winning bid and creative payload to the SDK.
- The SDK renders the creative in a WebView or, where possible, maps structured native assets to native UI components.
Advantages:
- Auction latency is offloaded to the server, reducing time-to-render on device.
- Lower CPU and memory footprint because Prebid.js does not run on the client.
- Centralized demand partner configuration -- changes take effect without an SDK update.
- Better suited for resource-constrained devices and high-frequency ad refresh scenarios.
Limitations:
- Requires a running Prebid Server instance (Sellwild hosts this at
prebid.sellwild.com). - Demand partner support is limited to adapters available in Prebid Server (Go or Java).
- Slightly more complex initial setup compared to Mode A.
Configuration:
SellwildSDK.configure({
publisherId: 'your-publisher-id',
prebidMode: 'server',
prebidServerUrl: 'https://prebid.sellwild.com',
});Mode C: Prebid Mobile SDK (Future)
Mode C integrates the Prebid Mobile SDK directly into the native layer. This mode is on the roadmap for a future release and targets publishers who need fully native ad rendering without any WebView dependency.
How it works:
- The Prebid Mobile SDK is embedded as a native dependency alongside the Sellwild SDK.
- Bid requests are sent via the Prebid Mobile SDK's built-in networking layer, either directly to demand partners or through Prebid Server.
- Native demand responses are mapped to platform-native UI components (UIKit/SwiftUI on iOS, Jetpack Compose/Views on Android).
- No WebView is used at any stage of the rendering pipeline.
Advantages:
- Fully native rendering for the best possible user experience and performance.
- Deep integration with platform accessibility and layout systems.
- No WebView overhead whatsoever.
Limitations:
- Significantly more implementation effort on each platform.
- Requires the Prebid Mobile SDK as an additional native dependency, increasing binary size.
- Not yet available -- currently in the design phase.
Comparison Table
| Mode A: Prebid.js WebView | Mode B: Prebid Server S2S | Mode C: Prebid Mobile SDK | |
|---|---|---|---|
| Auction location | Client (WebView) | Server (prebid.sellwild.com) | Client (native) |
| Rendering | WebView | WebView or hybrid native | Fully native |
| Latency | Higher (client-side auction) | Lower (server-side auction) | Lowest (no WebView) |
| Device resource usage | Moderate (WebView + JS engine) | Low (network call only) | Low (native only) |
| Adapter ecosystem | Full Prebid.js adapters | Prebid Server adapters | Prebid Mobile adapters |
| Infrastructure required | None | Prebid Server instance | None |
| Configuration changes | Requires SDK update | Server-side, no SDK update | Requires SDK update |
| Status | Available (default) | Available | Planned |
When to Use Which Mode
Choose Mode A when you need the fastest integration path, already have Prebid.js configurations, or want to maximize demand partner reach through the full Prebid.js adapter library.
Choose Mode B when latency is a priority, you want centralized demand configuration, or you are running ads on devices where WebView auction overhead is a concern. Mode B is the recommended mode for production deployments that require predictable ad load times.
Choose Mode C (once available) when your app demands fully native ad rendering with zero WebView usage, or when platform-specific accessibility and layout integration is a hard requirement.
Migration Path: A to B to C
The SDK is designed so that switching modes requires only a configuration change, not a re-integration.
A to B
- Ensure your Prebid Server account is provisioned. Contact the Sellwild team to confirm your demand partner configuration is mirrored on
prebid.sellwild.com. - Update the SDK configuration to set
prebidModeto'server'and provide theprebidServerUrl. - Test in a staging environment. Validate that fill rates and latency meet expectations.
- Roll out to production. No changes to ad placement code are required.
// Before (Mode A -- default)
SellwildSDK.configure({
publisherId: 'your-publisher-id',
});
// After (Mode B)
SellwildSDK.configure({
publisherId: 'your-publisher-id',
prebidMode: 'server',
prebidServerUrl: 'https://prebid.sellwild.com',
});B to C
- Update the Sellwild SDK to the version that includes Mode C support (release TBD).
- Add the Prebid Mobile SDK as a native dependency on each platform.
- Update the SDK configuration to set
prebidModeto'native'. - Replace any custom WebView-based ad view styling with native layout configuration.
// Mode C (future)
SellwildSDK.configure({
publisherId: 'your-publisher-id',
prebidMode: 'native',
});Each migration step is backward-compatible. If issues arise after switching modes, reverting to the previous mode is a single configuration change.