Cobrowse.io Docs
  • Getting started
  • SDK Installation
    • Web
    • iOS
    • Android
    • React Native
    • Flutter
    • .NET Mobile
    • macOS
    • Windows
  • SDK Features
    • Account config
    • Identify your devices
    • Use 6-digit codes
    • Redact sensitive data
    • Viewing PDFs
    • Universal Cobrowse
    • Customize the interface
      • Active session controls
      • 6-digit code screen
      • User consent dialog
      • Remote control consent dialog
      • Full device consent dialog
      • Localization / translation
    • Initiate sessions with push
    • Listening for events
    • Full device capabilities
      • Full device screen sharing
      • Full device remote control
      • Managing full device mode
    • Advanced configuration
      • Starting and stopping the SDK
      • Declaring capabilities
      • Intercepting mobile SDK network requests
      • Web
        • IFrames support
        • IE 11 polyfills
        • Cross-domain session support
        • Ignore Views
      • iOS
        • Alternate render method
        • Custom touch handling
      • Android
        • Backporting TLS to older Android versions
  • Agent-side integrations
    • Agent-side overview
    • Platform integrations
      • Zendesk
      • Salesforce
        • Migrating from legacy to v2
        • Salesforce (Legacy)
      • Genesys
        • Genesys Cloud
        • Engage Workspace Web Edition (WWE)
        • Engage Workspace Desktop Edition (WDE)
      • Intercom
      • Freshworks
      • Talkdesk
      • NICE
    • Custom integrations
    • Agent SDK
      • API Reference
      • Sample code snippets
    • Authentication (JWTs)
      • JWT Policies
    • Authentication (SAML 2.0)
    • IFrame embeds
  • Enterprise self-hosting
    • Self-hosting overview
    • Docker Compose
    • Helm chart
      • Image Pull Secret
      • Environment Variables
      • Optional recording components
      • Pod Annotations
    • AWS terraform
      • AWS metrics configuration
    • Azure terraform
      • Azure metrics configuration
    • GCP terraform
      • GCP metrics configuration
    • Sizing guidelines
    • Running your instance
      • Adding a superuser
      • Limiting account creation
      • Limiting magic link recipients
      • Configuring SMTP
      • Managing your deployment
    • Monitoring your instance
      • Available metrics
      • Self-Hosted Prometheus
    • Advanced configuration
      • Air gap configuration
      • Pin web SDK version
      • L7 firewall configuration
      • Docker proxy configuration
    • Troubleshooting
Powered by GitBook
On this page
  • Cross-document IFrames
  • Redaction within cross-document IFrames
  • Running only in an IFrame

Was this helpful?

  1. SDK Features
  2. Advanced configuration
  3. Web

IFrames support

To use Cobrowse for Web with cross document IFrames you will need to add a javascript snippet to the page being embedded.

PreviousWebNextIE 11 polyfills

Last updated 3 months ago

Was this helpful?

Cross-document IFrames

IFrames that are not cross document are supported out-of-box without adding the SDK to the embedded page. This guide is for supporting cross document IFrames.

To use Cobrowse for Web with cross document IFrames you will need to add our javascript snippet to the page being embedded. You will then need to add a list of trusted origins to the embedded page and the parent page:

CobrowseIO.trustedOrigins = [
    'https://myexample.com', // parent origin to trust
    'https://my-other-website.net' // another parent origin to trust
];
CobrowseIO.start();

It is not necessary for the embedded page to contain the Cobrowse license key, if provided it will be ignored.

Code example

See our JS examples repo for the parent and child SDK configuration: .

Redaction within cross-document IFrames

Elements within the cross-document iframe can also be redacted by using the URL of the iframe as the key to the array of Selectors to be redacted just for that iframe.

Full details can be seen at the link below.

Running only in an IFrame

A few customers want to run Cobrowse.io only within an IFrame, and not any containing or parent page. This is supported, but requires passing an extra configuration option when starting Cobrowse.

CobrowseIO.start({allowIFrameStart:true});

https://github.com/cobrowseio/cobrowse-sdk-js-examples#cross-document-iframes
Redact sensitive data