---
metadata:
  - name: generator
    content: Diplodoc Platform v5.55.0
alternate:
  - https://yandex.com/support/adfox/en/targeting/time.md
  - https://yandex.com/support/adfox/ru/targeting/time.md
  - href: en/targeting/time.md
    type: text/markdown
    title: Markdown version
  - href: ../llms.txt
    type: text/markdown
    title: llms.txt
---
> **Documentation Index:** Fetch the complete configuration index at https://yandex.com/support/adfox/en/llms.txt

# By time

To set up targeting by time:

1. Go to **Targeting** → **Add a targeting condition** → **By time**.
1. You can set up targeting:

    - Hour: Select any hour of any day of the week when you want your ads to run. To add or remove entire rows (days of the week) and columns (hours), click the name of the day or hour.
    - Days of the month: Select the days of the month when you want your ads to run.

1. <!-- source: en/_includes/targeting/add-condition.md -->
   Click **Apply** and save the targeting criteria.
   <!-- endsource: en/_includes/targeting/add-condition.md -->

{% note info %}

You can't disable days and hours for banners if:

- The campaign's ad running speed is set to **spread evenly** (throughout the day, throughout the entire period, or throughout the entire period with automatic prolongation).
- These days and hours are prohibited (disabled) in the **By time** targeting for the campaign.

You can still disable banner impressions on those hours and days that are enabled in the campaign.

{% endnote %}


## User's time {#time_of_user}

Adfox automatically detects the user's region by IP address and correctly displays their local time. This allows you to correctly apply time-based targetings without any additional setup.

You can manually pass time parameters directly in the request. In this case, they take precedence over the automatic values. If a request contains a specific time or time zone, the system prioritizes this data.


{% cut "Technical features of targeting by time" %}


When the **User's time** option is enabled, passing the user's time in the system request is a prerequisite for correct targeting.

The embed code has the `pt` parameter that defines which time will be used:

##### **pt=a**

Moscow time of the server.

##### **pt=b**

User's time (of the visitor to the site): in this case, it's mandatory to pass the user's time values in the request code to the variables `pv`, `pd`, and `pw`. If the request is sent with `pt=b` with no time values passed, Moscow time is used.

##### **pd**

Day of the month: a number from 1 through 31.

##### **pw**

Day of the week: a number from 0 through 6, where 0 is Sunday, 1 is Monday, 2 is Tuesday, and so on.

##### **pv**

Client hour: a number from 0 through 23.

{% endcut %}

Even if you enable the **User's time** option to target users based on their local time, Adfox always records statistics in UTC+3.

> For example, suppose a banner is configured to target users in Khabarovsk from 09:00 to 09:59, with the **User's time** option enabled. This means that the targeting condition will be met when a user in Khabarovsk is shown the banner at `09:00`. In Moscow, this will be `02:00`. This means that the impression for this banner will be recorded in the report at `02:00`.


## Targeting by day of the month {#section_frq_fn4_mfb}

Go to **Targeting** → **by days of the month**, select the days of the month when you want to serve impressions, then click **Change**.

<!-- source: en/_includes/feedback.md -->
## Contact support


<a href="en/form"> <!--ссылка, куда ведет кнопка. Если внутренняя ссылка, пишем без .md и .html --> 
  <span class="button">Send an email</span> <!--текст на кнопке--> 
</a>



<!-- source: en/_includes/styles/button.md -->

<!-- endsource: en/_includes/styles/button.md -->
<!-- endsource: en/_includes/feedback.md -->


