---
updatedAt: 2025-06-17T21:44:33.000Z
agentTools:
  projectIndex: https://support.kissmetrics.io/llms.txt
---

# Identify

# \_kmq.push(\['identify', identity])

`identify` connects the current person with a unique ID, and attributes future events from this browser to this provided ID. If the current person is ‘anonymous’, it also connects their ‘anonymous’ ID to the provided ID so we recognize both as being the same person (aliasing). Calling identify does not count as an “event”.

<HTMLBlock>{`
<div style="width: calc(100% + 420px);">
  <iframe height="422" style="width: 100%;" scrolling="no" title="KM JS Library - Identify" src="https://codepen.io/team/kissmetrics/embed/KvGZgd?height=265&theme-id=light&default-tab=js,result" frameborder="no" allowtransparency="true" allowfullscreen="true" loading="lazy">
  See the Pen <a href='https://codepen.io/team/kissmetrics/pen/KvGZgd'>KM JS Library - Identify</a> by Kissmetrics
  (<a href='https://codepen.io/kissmetrics'>@kissmetrics</a>) on <a href='https://codepen.io'>CodePen</a>.
</iframe>
</div>
`}</HTMLBlock>

## Parameters

<Table align={["left","left","left"]}>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        Description
      </th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        identity\*
      </td>

      <td>
        string
      </td>

      <td>
        A unique ID to identify the current person.
      </td>
    </tr>

    <tr>
      <td>

      </td>

      <td>

      </td>

      <td>

      </td>
    </tr>
  </tbody>
</Table>

# \_kmq.push(\['set', properties, callback])

`set` sets properties for the current user.

<HTMLBlock>{`
<div style="width: calc(100% + 420px);">
  <iframe height="422" style="width: 100%;" scrolling="no" title="KM JS Library - Set" src="https://codepen.io/team/kissmetrics/embed/zdywWj?height=265&theme-id=light&default-tab=js,result" frameborder="no" allowtransparency="true" allowfullscreen="true" loading="lazy">
  See the Pen <a href='https://codepen.io/team/kissmetrics/pen/zdywWj'>KM JS Library - Set</a> by Kissmetrics
  (<a href='https://codepen.io/kissmetrics'>@kissmetrics</a>) on <a href='https://codepen.io'>CodePen</a>.
</iframe>
</div>
`}</HTMLBlock>

## Parameters

<Table align={["left","left","left"]}>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        Description
      </th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        property\*
      </td>

      <td>
        object
      </td>

      <td>
        The properties to set for the current user.
      </td>
    </tr>

    <tr>
      <td>
        callback
      </td>

      <td>
        function
      </td>

      <td>
        Function to be called after the properties are set.
      </td>
    </tr>
  </tbody>
</Table>

# \_kmq.push(\['clearIdentity'])

`clearIdentity` clears the current person's identity and generates a new anonymous ID for their browser. Does nothing if the current person is currently ‘anonymous’.

<HTMLBlock>{`
<div style="width: calc(100% + 420px);">
  <iframe height="422" style="width: 100%;" scrolling="no" title="KM JS Library - Clear Identity" src="https://codepen.io/team/kissmetrics/embed/VzqbVJ?height=265&theme-id=light&default-tab=js,result" frameborder="no" allowtransparency="true" allowfullscreen="true" loading="lazy">
  See the Pen <a href='https://codepen.io/team/kissmetrics/pen/VzqbVJ'>KM JS Library - Clear Identity</a> by Kissmetrics
  (<a href='https://codepen.io/kissmetrics'>@kissmetrics</a>) on <a href='https://codepen.io'>CodePen</a>.
</iframe>
</div>
`}</HTMLBlock>