# Naming convention

A naming convention is one row per segment of a name. Each row fixes a position, a token, what the token means, the complete list of values it may take, and who owns that list.

The point is not tidiness. A name built from fixed positions and a closed list of values can be split by a script, which means an account can be grouped, filtered and reported on without anybody maintaining a mapping table by hand.

## How to use it

1. Copy this file, or the CSV version if you would rather work in a sheet.
2. Decide the separator first, and pick one that cannot appear inside a value.
3. Fix the positions before the values, so a name can be split by position.
4. List the allowed values for every position, and give each list an owner.
5. Put optional segments at the end, never in the middle.
6. Write one full example name for every level, and check it splits correctly.
7. Agree the change rule before anybody renames anything that is already running.

## The columns

**Level** (Text). Which object this segment belongs to: campaign, ad set or ad group, ad, creative file, or a tracking parameter. A convention that does not say the level cannot be applied consistently.

**Position** (Integer). Where the segment sits in the name, counting from the left. Fixed positions are what let a name be split by a script rather than read by a person.

**Token** (Text). The short code that appears in the name: the literal text, not a description of it. Tokens are lower case, have no spaces, and never contain the separator.

**Meaning** (Text). What the token stands for, in plain words. This column is the reason somebody six months from now can read a name they did not write.

**Allowed values** (Text). The complete list of values this position may take, or the rule that generates them. An open-ended position is a position that will hold anything within a month.

**Example** (Text). A real value in this position, written as it will appear. One concrete example prevents more misreadings than a paragraph of description.

**Required** (Text). Whether this segment must appear, or may be omitted. A convention with optional segments in the middle cannot be split reliably, so optional segments belong at the end.

**Separator** (Text). The character between this segment and the next. One separator, used everywhere, and never a character that appears inside a token.

**Case rule** (Text). How the value is cased: lower case throughout is the only rule that survives contact with several people and several platforms.

**Where it appears** (Text). Every place this segment has to be repeated: the campaign name, the file name, the tracking parameter, the plan. Consistency across those is the whole benefit.

**Maintained by** (Text). Who owns the list of allowed values for this position, and who adds to it. A list nobody owns is a list that grows a synonym for everything in it.

**Change rule** (Text). What happens when this segment has to change. Renaming live objects breaks reporting history, so the rule is usually that names are set once and new objects get new names.

**Notes** (Text). Anything the next person needs: a value that was retired and why, a platform that truncates long names, a position that exists only for historical reasons.

## The naming convention

| Level | Position | Token | Meaning | Allowed values | Example | Required | Separator | Case rule | Where it appears | Maintained by | Change rule | Notes |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
|   |   |   |   |   |   |   |   |   |   |   |   |   |
|   |   |   |   |   |   |   |   |   |   |   |   |   |
|   |   |   |   |   |   |   |   |   |   |   |   |   |
|   |   |   |   |   |   |   |   |   |   |   |   |   |

## Before you commit it

- One separator is used everywhere, and it never appears inside a value.
- Every position is fixed, and optional segments sit at the end.
- Every position has a closed list of allowed values with a named owner.
- Every level has one full example name written out.
- Every example splits correctly on the separator.
- The change rule is agreed before anybody renames a live object.
- Retired values are recorded rather than deleted.
