> ## Documentation Index
> Fetch the complete documentation index at: https://docs.invoca.com/llms.txt
> Use this file to discover all available pages before exploring further.

# How to Target Specific Numbers to Swap Using a CSS Class or ID

> Swap only specific numbers on a page by either listing them directly in the Tag Wizard, or targeting them with a CSS selector in custom code.

If you'd rather swap specific numbers on your page instead of replacing every detected number, you have two options.

## Option 1: Replace specific phone numbers in the Tag Wizard

If you know the full list of numbers to replace, set them directly in the Tag Wizard, along with the desired campaign for each. Vanity numbers can also be added this way.

## Option 2: Use a numberSelector

If you're not certain of the complete list of numbers to swap, use a CSS selector — such as a class name, ID, or attribute name — in your custom code instead.

1. Identify the correct CSS selector for the numbers you want to swap. This may require review from a technical resource on your side.
2. Add the selector as a string to `options.numberSelector` in your custom code. For example, if targeting a class name of `tel1`, add that class name as the selector value.
3. The Invoca Tag will only swap numbers matching the CSS selectors configured in your custom code.
4. Make sure no checkboxes are selected in the Tag Wizard UI for **Replace any detected** or **Replace Specific**:
   * If a checkbox is selected, it works in conjunction with the number selector.
   * If the number selector isn't found on the page, the Tag falls back to detecting numbers based on the selected checkboxes.
5. To exclude specific numbers from swapping, simply don't include their selectors in your custom code — the Tag won't identify or replace those numbers.

Reach out to your account team or [support@invoca.com](mailto:support@invoca.com) to engage Invoca Technical Services for help with this setup.

## Where to go next

* [Tag Wizard: Custom Code Settings](/s/article/tag-wizard-custom-code-settings)
* [Configure the Invoca Tag to Selectively Swap for Paid Media Sources](/s/article/selectively-swap-paid-media)
