How do I capture keystrokes in non-sensitive fields?

As part of our Terms of Service, you must explain in your privacy policy how you use our tracking software with your visitors.

If you have a Master Account, you can control how much or how little information you wish to record. By going to Settings » Privacy, you can select whether or not to record:

  • keystrokes
  • mouse clicks
  • mouse movements
  • scrolls

How to Capture Keystrokes

You must do two things to enable the capturing of keystroke data on your site:

  1. Explicitly opt out of keystroke blocking by going to Settings » Privacy and unchecking the box labeled Do not record keystrokes. Note, however, that Lucky Orange will still block certain things like passwords, credit card information, etc. Read more about limitations.
  2. Add a class of LoNotSensitive to each field you want to capture.

Keystroke Logging Limitations

Password field data is never recorded or transmitted. No matter what. Even if you add the LoNotSensitive class name to a password field. Lucky Orange has no need for others' passwords, and neither should you.

Note: Lucky Orange also scans for certain input fields with names that denote their contents as potentially containing sensitive information, such as ccn, card-number, cvv2, etc. As with password fields, these fields are internally marked as sensitive, and cannot be overridden.


Imagine you have a text field to input a gender like this:

<input type="text" name="gender" />

The only thing Lucky Orange needs is the special class name to be added to the input. So, we add the LoNotSensitive class name:

[comment text="Add `LoNotSensitive` to the <input> tag to log character data." lang="html"]
<input type="text" name="gender" [b]class="LoNotSensitive"[/b] />

If your text field already has a class name — or multiple class names — simply add a space, followed by the LoNotSensitive class name, like so:

[comment text="Just add `LoNotSensitive` after any classes (e.g. `inline-field`)." lang="html"]
<input type="text" name="gender" class="inline-field [b]LoNotSensitive[/b]" />

Or you can add the class name anywhere within the class attribute's quotation marks:

[comment text="Add it at the beginning if you want." lang="html"]
<input type="text" name="gender" class="[b]LoNotSensitive[/b] inline-field form-data">
[comment text="Or in the middle:" lang="html"]
<input type="text" name="gender" class="inline-field [b]LoNotSensitive[/b] form-data">

Marking Elements as Not Sensitive Without Access to the HTML

Sometimes you cannot edit the html of the form but still have the ability to add javascript to the page. If that is the case you can add the following global array to the page that lists the IDs of the elements that are not sensitive. This is the same as adding the LoNotSensitive class to them.

window.__lo_not_sensitive_ids = ["element_id","other_element_id"];

Still need help? Contact Us Contact Us