# OTP generation by Hideez Authenticator App for 2FA

Hideez Authenticator allows user to generate One-Time Passwords for [Two-Factor Authentication](https://fidoalliance.org/specs/u2f-specs-master/fido-u2f-overview.html) mechanism.

To use OTP generation feature first you have to [enroll your Hideez Authenticator on HES](/use-cases/hideez-authenticator-mobile-app/using-hideez-authenticator-as-your-two-factor-authentication-method-for-sso.md).

## Set up two-factor authentication for your Gmail account

### Step 1: Enable two-factor authentication according to [Google’s instructions](https://support.google.com/accounts/answer/1066447?hl=en\&co=GENIE.Platform%3DAndroid\&oco=0).&#x20;

### Step 2: Open a secret key to generate OTP passwords in the account data.

To do this, go to account editing mode and&#x20;

**OR**&#x20;

when setting up Google Authenticator, click **CAN'T SCAN IT?**\
&#x20;&#x20;

![](/files/-MA61y7IK1RvRmUq_gFA)

<figure><img src="/files/5zy0YJGCV9rA9NvTTgbL" alt=""><figcaption></figcaption></figure>

### Step 3: Add OTP account

You can add an OTP secret either by scanning a QR code or manually.

1. Open the "Accounts" section.\
   \
   ![](/files/eYP79YcUFxCJWkxCZlTs)<br>
2. Tap the "+" button.\
   \
   ![](/files/mAt7bkM6YfDU53BBghFK)<br>
3. Then you can either scan QR code from the Google account settings or enter it manually:<br>
   * Scan a QR code:\
     \
     ![](/files/iUMw8EcthWOEGhAk4jjb)<br>
   * Tap "Add manually" button:\
     \
     ![](/files/7Rr4XuOVl146zOTB57XZ)\
     \
     Type the account name and secret key in the corresponding fields.\
     \
     ![](/files/msPwIUHjBGeFvcX2z2bO)\
     \
     You also can provide advanced parameters such as a OTP length, Hash Algorithm and valid period. Just switch the "Advanced options" trigger to set them up.\
     \
     ![](/files/J6ZaRbogtaMGfqmLEjjg) ![](/files/x8d7RvPSMu26gNK12qgO)\
     \
     Tap the "Add" button.\
     \
     ![](/files/L401ljV6ZazXK7KYFuhi)

### Step 4: Confirm OTP in your Google account

1. Then click on the **Next** button. Enter OTP that is displayed in Hideez Authenticator, "Accounts" section.\
   \
   ![](/files/BG4ItjW2A0HpgVEQ9e08) ![](/files/CuIztL4YWD40koZPnHIZ)<br>
2. Click **Verify**.\
   \
   ![](/files/SYEHN0Qj7rCrIRD3VYi2)

## Sign in to your Gmail account with two-factor authentication

### Step 1: Visit the <https://mail.google.com/> account login page

### Step 2: Enter your credentials (login and password)

### Step 3: Choose Google Authenticator app second-factor authentication method

Indicate whether you want to always pass two-factor authentication on this computer or not - clear or leave the checkbox **Don’t ask again on this computer** and also select **Try another way** and **Get a verification code from the Google Authenticator App:**

<figure><img src="/files/mHaQtRvThMFATEsVxa6O" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/iehyVtVUzO5YthmrDbpv" alt=""><figcaption></figcaption></figure>

### **Step 4: Enter OTP code**

Enter OTP that is displayed in Hideez Authenticator, "Accounts" section and click the **Next** button.\
\
![](/files/BG4ItjW2A0HpgVEQ9e08) ![](/files/LKmH5ETPcKBI9cqe5RrJ)

You can find more on OTP generation in Hideez Authenticator - [*iOS*](https://authenticator.hideez.com/user-guide/ios-guide/otp-generation), [*Android*](https://authenticator.hideez.com/user-guide/android-guide/otp-generation).


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://enterprise.hideez.com/use-cases/hideez-authenticator-mobile-app/using-hideez-authenticator-as-an-otp-generator-for-your-two-factor-authentication.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
