Moving Third-Party Cookies to a New Domain

Prev Next

The Cookie Control plugin moves existing server-side cookies to a new track domain, a new track ID, or both. Visitors who return while the plugin is active keep their everId.

Note

The plugin migrates server-side cookies only. Client-side cookies are not affected by a change of the track domain. If only the DNS record type behind your track domain changes, you do not need the plugin. See Switching Your Custom Track Domain from CNAME to A-Record.


Before You Start

Warning

Keep the previous track domain active while the plugin is running. The plugin calls it to transfer the cookies to the new track domain.

Read the notes on costs and activation in Cookie Control before you start.


Configuration

Choose your integration method:

Set the migration, then activate the plugin. These parameters describe the two setups:

Setup

Parameters

New setup

currentTrackId and currentTrackDomain

Previous setup

oldTrackId and oldTrackDomain

wtSmart.extension.cookie_control.config({
    action: '3->3',
    // use a date in the future
    lifeTime: '01 Jan 2030 00:00:00',
    // new setup
    currentTrackId: '222222222222222',
    currentTrackDomain: 'data.exampleshop.com',
    // previous setup
    oldTrackId: '111111111111111',
    oldTrackDomain: 'track.exampleshop.com'
});
wtSmart.extension.cookie_control.activate();

All parameters are described in Integration and Activation.

In the Tag Integration, the plugin is available only as a custom plugin. You enter your configuration in the content of this plugin. Requirements and the plugin file are described in Technical Requirements and Download. The integration is described in Integration and Activation.

Define the configuration before the first tracking request. These parameters describe the two setups:

Setup

Parameters

New setup

trackId and trackDomain inside action

Previous setup

trackId and trackDomain on the top level

var wtcc_config = {
    // previous setup
    trackId: '111111111111111',
    trackDomain: 'track.exampleshop.com',
    // use a date in the future
    lifeTime: '01 Jan 2030 00:00:00',
    action: {
        // new setup
        trackId: '222222222222222',
        trackDomain: 'data.exampleshop.com',
        action: '3->3'
    }
};

All parameters are described in Integration and Activation.


After the Migration

When the integration period agreed with Mapp ends, complete these steps:

  1. Remove the plugin from your website.

  2. Update the remaining parts of your setup as described in Adjusting Your Setup After a Track Domain Change.