{"id":8824,"date":"2026-11-20T13:24:14","date_gmt":"2026-11-20T10:24:14","guid":{"rendered":"https:\/\/help.bothelp.io\/formula-daty-i-vremya\/"},"modified":"2026-11-20T13:54:14","modified_gmt":"2026-11-20T10:54:14","slug":"formula-daty-i-vremya","status":"publish","type":"post","link":"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/","title":{"rendered":"Formula: Dates and Time"},"content":{"rendered":"<p>The functions in this group work with dates: they add days and months, calculate differences, convert a date to the right format and write it out in Russian.<\/p>\r\n<p><strong>Where it helps:<\/strong><\/p>\r\n<ul>\r\n<li>calculate the subscriber&#8217;s age or the time since a purchase;<\/li>\r\n<li>get the date in N days \u2014 for example, the end of a trial period;<\/li>\r\n<li>show a date in words, for example &#8220;3 \u0430\u043f\u0440\u0435\u043b\u044f 2026, \u043f\u044f\u0442\u043d\u0438\u0446\u0430&#8221;.<\/li>\r\n<\/ul>\r\n<h2>Functions<\/h2>\r\n\n<table id=\"tablepress-8\" class=\"tablepress tablepress-id-8\">\n<thead>\n<tr class=\"row-1\">\n\t<th class=\"column-1\"><strong>Function<\/strong><\/th><th class=\"column-2\"><strong>Description<\/strong><\/th><th class=\"column-3\"><strong>Example<\/strong><\/th>\n<\/tr>\n<\/thead>\n<tbody class=\"row-striping row-hover\">\n<tr class=\"row-2\">\n\t<td class=\"column-1\">get_current_time()<\/td><td class=\"column-2\">Returns the current date and time in the cabinet\u2019s time zone. Format: %Y-%m-%d %H:%M:%S.<\/td><td class=\"column-3\">globals.now = get_current_time() \u2192 \"2025-11-11 16:30:00\"<\/td>\n<\/tr>\n<tr class=\"row-3\">\n\t<td class=\"column-1\">addYear(date, years)<\/td><td class=\"column-2\">Adds or subtracts years (taking leap years into account). Use a negative number to subtract.<\/td><td class=\"column-3\">addYear(\"2020-01-01\", 3) \u2192 \"2023-01-01\"<\/td>\n<\/tr>\n<tr class=\"row-4\">\n\t<td class=\"column-1\">addMonth(date, months)<\/td><td class=\"column-2\">Adds or subtracts months (takes month lengths and leap years into account).<\/td><td class=\"column-3\">addMonth(\"2025-01-10\", 2) \u2192 \"2025-03-10\"<\/td>\n<\/tr>\n<tr class=\"row-5\">\n\t<td class=\"column-1\">addDays(date, days)<\/td><td class=\"column-2\">Adds or subtracts days. Use a negative number to subtract.<\/td><td class=\"column-3\">addDays(\"20.08.2019\", -99) \u2192 \"13.05.2019\"<\/td>\n<\/tr>\n<tr class=\"row-6\">\n\t<td class=\"column-1\">addHours(date, hours)<\/td><td class=\"column-2\">Adds or subtracts hours. Use a negative number to subtract.<\/td><td class=\"column-3\">addHours(\"2026-04-03 10:00:00\", 3) \u2192 \"2026-04-03 13:00:00\"<\/td>\n<\/tr>\n<tr class=\"row-7\">\n\t<td class=\"column-1\">addMinutes(date, minutes)<\/td><td class=\"column-2\">Adds or subtracts minutes (for \"Date and Time\" values).<\/td><td class=\"column-3\">addMinutes(get_current_time(), 20) \u2192 \"2025-11-11 16:50:00\"<\/td>\n<\/tr>\n<tr class=\"row-8\">\n\t<td class=\"column-1\">addWeeks(date, weeks)<\/td><td class=\"column-2\">Adds or subtracts weeks. Use a negative number to subtract.<\/td><td class=\"column-3\">addWeeks(\"2026-04-03\", 1) \u2192 \"2026-04-10\"<\/td>\n<\/tr>\n<tr class=\"row-9\">\n\t<td class=\"column-1\">format_date(date, \"\u0444\u043e\u0440\u043c\u0430\u0442\")<\/td><td class=\"column-2\">Converts a date to the specified format. Supported formats: %Y-%m-%d, %d.%m.%Y, %Y-%m-%d %H:%M:%S, %d.%m.%Y %H:%M:%S.<\/td><td class=\"column-3\">format_date(\"2025-10-10\", \"%d.%m.%Y\") \u2192 \"10.10.2025\"<\/td>\n<\/tr>\n<tr class=\"row-10\">\n\t<td class=\"column-1\">convert_datetime(date, input_format, output_format)<\/td><td class=\"column-2\">Converts a date from one format to another. Formats use codes: %Y \u2014 year, %m \u2014 month, %d \u2014 day, %H \u2014 hours, %M \u2014 minutes, %S \u2014 seconds.<\/td><td class=\"column-3\">convert_datetime(\"2011\/11\/03\", \"%Y\/%m\/%d\", \"%d.%m.%Y\") \u2192 \"03.11.2011\"<\/td>\n<\/tr>\n<tr class=\"row-11\">\n\t<td class=\"column-1\">date_diff(date1, date2, unit)<\/td><td class=\"column-2\">Returns the difference between two dates. The unit parameter can be \"days\" or \"minutes\".<\/td><td class=\"column-3\">date_diff(client.birth_date, get_current_time(), \"days\") \u2192 9125<\/td>\n<\/tr>\n<tr class=\"row-12\">\n\t<td class=\"column-1\">date_rus(date, with_year)<\/td><td class=\"column-2\">Returns the date written in Russian: day and month. To add the year, pass True as the second argument. If no date is given, uses the current date in the account time zone.<\/td><td class=\"column-3\">date_rus(\"2026-04-03\") \u2192 \"3 \u0430\u043f\u0440\u0435\u043b\u044f\"<br>date_rus(\"2026-04-03\", True) \u2192 \"3 \u0430\u043f\u0440\u0435\u043b\u044f 2026\"<\/td>\n<\/tr>\n<tr class=\"row-13\">\n\t<td class=\"column-1\">weekday(date)<\/td><td class=\"column-2\">Returns the day of the week as a number from 1 to 7: Monday is 1, Sunday is 7. If no date is given, uses the current date in the account time zone.<\/td><td class=\"column-3\">weekday(\"2026-04-03\") \u2192 5<\/td>\n<\/tr>\n<tr class=\"row-14\">\n\t<td class=\"column-1\">weekday_name(date)<\/td><td class=\"column-2\">Returns the name of the day of the week in Russian, in lowercase. If no date is given, uses the current date in the account time zone.<\/td><td class=\"column-3\">weekday_name(\"2026-04-03\") \u2192 \"\u043f\u044f\u0442\u043d\u0438\u0446\u0430\"<\/td>\n<\/tr>\n<tr class=\"row-15\">\n\t<td class=\"column-1\">timestamp(date)<\/td><td class=\"column-2\">Returns Unix time: the number of seconds since January 1, 1970 (UTC). The date is read in the account time zone. If no date is given, uses the current time.<\/td><td class=\"column-3\">timestamp(\"2026-01-01 03:00:00\") \u2192 1767225600 (for an account in Moscow time)<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<!-- #tablepress-8 from cache -->\r\n<h2>Good to know<\/h2>\r\n<ul>\r\n<li>Variables of the &#8220;Date&#8221; and &#8220;Date and time&#8221; types are stored in the internal format <code>YYYY-MM-DD<\/code>. For example, the input <code>11.11.2011<\/code> is stored as <code>\"2011-11-11\"<\/code>.<\/li>\r\n<li>All operations are performed in the account time zone.<\/li>\r\n<li>Multiplying or dividing dates causes a &#8220;Type error&#8221;.<\/li>\r\n<li>In <code>date_diff<\/code>, date1 is subtracted from date2.<\/li>\r\n<\/ul>\r\n<h2>Example: age and forecast<\/h2>\r\n<p>Let&#8217;s calculate the subscriber&#8217;s age and make a forecast based on it. First, ask for the birth date and save the answer to the <strong>birth_date<\/strong> variable of the &#8220;Date&#8221; type.<\/p>\r\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-6489\" src=\"https:\/\/help.bothelp.io\/wp-content\/uploads\/2025\/10\/image-12-1024x284.png\" alt=\"\" width=\"1103\" height=\"306\" srcset=\"https:\/\/help.bothelp.io\/wp-content\/uploads\/2025\/10\/image-12-1024x284.png 1024w, https:\/\/help.bothelp.io\/wp-content\/uploads\/2025\/10\/image-12-300x83.png 300w, https:\/\/help.bothelp.io\/wp-content\/uploads\/2025\/10\/image-12-768x213.png 768w, https:\/\/help.bothelp.io\/wp-content\/uploads\/2025\/10\/image-12-1536x425.png 1536w, https:\/\/help.bothelp.io\/wp-content\/uploads\/2025\/10\/image-12-2048x567.png 2048w\" sizes=\"auto, (max-width: 1103px) 100vw, 1103px\" \/><\/p>\r\n<p>Then in the &#8220;Formula&#8221; step:<\/p>\r\n<ol>\r\n<li>Use <strong>date_diff<\/strong> to calculate the difference in days between <strong>birth_date<\/strong> and the current date <strong>get_current_time<\/strong>.<\/li>\r\n<li>Use <strong>int<\/strong> to drop the fractional part and get the full number of years.<\/li>\r\n<li>Use <strong>if<\/strong> to save the answer to the <strong>forecast<\/strong> variable.<\/li>\r\n<\/ol>\r\n\r\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:false,&quot;fullScreenButton&quot;:false,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;python&quot;,&quot;mime&quot;:&quot;text\/x-python&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:true,&quot;lineWrapping&quot;:true,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;Python&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;python&quot;}\">client.age_years = int(date_diff(client.birth_date, get_current_time(), &quot;days&quot;) \/ 365)\r\nclient.forecast = if(client.age_years &gt;= 30, &quot;Now is the time for consistency and stability \ud83d\udc4c&quot;, &quot;A period of experiments and growth, try something new \ud83d\udcab&quot;)<\/pre><\/div>\r\n\r\n\r\n<p>And show the answer to the subscriber in the flow:<\/p>\r\n<p><code>You are {%age_years%} years old {%forecast%}<\/code><\/p>\r\n<h2>Example: a date in words<\/h2>\r\n\r\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:false,&quot;fullScreenButton&quot;:false,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;python&quot;,&quot;mime&quot;:&quot;text\/x-python&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:true,&quot;lineWrapping&quot;:true,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;Python&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;python&quot;}\">client.today_text = date_rus(get_current_time(), True) + &quot;, &quot; + weekday_name(get_current_time())<\/pre><\/div>\r\n\r\n\r\n<p><code>today_text<\/code> gets, for example, <code>3 \u0430\u043f\u0440\u0435\u043b\u044f 2026, \u043f\u044f\u0442\u043d\u0438\u0446\u0430<\/code>. <code>date_rus<\/code> and <code>weekday_name<\/code> return Russian text.<\/p>\r\n<h2>Example: the end of a trial period<\/h2>\r\n\r\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:false,&quot;fullScreenButton&quot;:false,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;python&quot;,&quot;mime&quot;:&quot;text\/x-python&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:true,&quot;styleActiveLine&quot;:true,&quot;lineWrapping&quot;:true,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;Python&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;python&quot;}\">client.trial_end = addDays(get_current_time(), 14)\r\nclient.trial_end_text = format_date(client.trial_end, &quot;%d.%m.%Y&quot;)<\/pre><\/div>\r\n\r\n\r\n<p>If today is April 3, 2026, <code>trial_end_text<\/code> gets <code>17.04.2026<\/code>.<\/p>\r\n<p>Business hours, the nearest event dates and birthdays are described in <a href=\"https:\/\/help.bothelp.io\/en\/formula-schedules-and-reminders\/\">Formula: Schedules and Reminders<\/a>. A ready-made template for parsing a birth date is in <a href=\"https:\/\/help.bothelp.io\/en\/formula-ready-made-templates\/\">Formula: Ready-Made Templates<\/a>.<\/p>\r\n<hr \/>\r\n<p>If you did not find the answer to your question, feel free to contact us in the chat inside your dashboard, message us on Telegram at <a href=\"https:\/\/t.me\/BotHelpSupportBot\" target=\"_blank\" rel=\"noopener\"><strong>@BotHelpSupportBot<\/strong><\/a>, or email us at <a href=\"mailto:hello@bothelp.io\" target=\"_blank\" rel=\"noopener\"><strong>hello@bothelp.io<\/strong><\/a>.<\/p>\r\n<p>Enjoy the full functionality of the BotHelp platform for creating broadcasts, automated funnels, and chatbots \u2014 free for 14 days.<\/p>\r\n<p><a href=\"https:\/\/bothelp.io\/?utm_source=bz&#038;utm_medium=footer&#038;utm_campaign=16881\"><strong>Get 14 Days Free<\/strong><\/a><\/p>\r\n\t\t\t<div id=\"daexthefu-container\"\r\n\t\t\t\tclass=\"daexthefu-container daexthefu-layout-side-by-side daexthefu-alignment-left\"\r\n\t\t\t\tdata-post-id=\"8824\">\r\n\r\n\t\t\t\t<div class=\"daexthefu-feedback\">\r\n\t\t\t\t\t<div class=\"daexthefu-text\">\r\n\t\t\t\t\t\t<h3 class=\"daexthefu-title\">\u0411\u044b\u043b\u0430 \u043b\u0438 \u0441\u0442\u0430\u0442\u044c\u044f \u043f\u043e\u043b\u0435\u0437\u043d\u0430?<\/h3>\r\n\t\t\t\t\t<\/div>\r\n\t\t\t\t\t<div class=\"daexthefu-buttons-container\">\r\n\t\t\t\t\t\t<div class=\"daexthefu-buttons\">\r\n\t\t\t\t\t\t\t\n\t\t\t<button type=\"button\" class=\"daexthefu-yes daexthefu-button daexthefu-button-type-icon\" data-value=\"1\" aria-label=\"Yes\">\n\t\t\t\t\n                <svg>\n                    <defs>\n                        <style>.thumb-up-cls-1{fill:#c9c9c9;}.thumb-up-cls-2{fill:#e1e1e1;}.thumb-up-cls-3{fill:#676767;}<\/style>\n                    <\/defs>\n                    <g id=\"thumb_up\">\n                        <path class=\"thumb-up-cls-2 daexthefu-icon-circle\" d=\"m24,3c11.58,0,21,9.42,21,21s-9.42,21-21,21S3,35.58,3,24,12.42,3,24,3m0-1C11.85,2,2,11.85,2,24s9.85,22,22,22,22-9.85,22-22S36.15,2,24,2h0Z\" \/>\n                        <g>\n                            <rect class=\"thumb-up-cls-3 daexthefu-icon-secondary-color\" x=\"10\" y=\"20\" width=\"6\" height=\"15\" rx=\"1.5\" ry=\"1.5\" \/>\n                            <path class=\"thumb-up-cls-1 daexthefu-icon-primary-color\" d=\"m30.57,9.06l-.49-.1c-.81-.17-1.61.35-1.78,1.16l-5.3,11.74c-.17.81,3.16,1.61,3.97,1.78l1.96.41c.81.17,1.61-.35,1.78-1.16l2.18-10.27c.34-1.61-.7-3.21-2.31-3.56Z\" \/>\n                            <path class=\"thumb-up-cls-1 daexthefu-icon-primary-color\" d=\"m38.17,20h-18.67c-.83,0-1.5.67-1.5,1.5v12c0,.83.67,1.5,1.5,1.5h16.27c.71,0,1.33-.5,1.47-1.21l2.4-12c.19-.93-.53-1.8-1.47-1.8Z\" \/>\n                        <\/g>\n                    <\/g>\n                <\/svg>\t\t\t<\/button>\n\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t<button type=\"button\" class=\"daexthefu-no daexthefu-button daexthefu-button-type-icon\" data-value=\"0\" aria-label=\"No\">\n\t\t\t\t\n                <svg>\n                    <defs>\n                        <style>.thumb-down-cls-1{fill:#c9c9c9;}.thumb-down-cls-2{fill:#e1e1e1;}.thumb-down-cls-3{fill:#676767;}<\/style>\n                    <\/defs>\n                    <g id=\"thumb_down\">\n                        <path class=\"thumb-down-cls-2 daexthefu-icon-circle\" d=\"m24,3c11.58,0,21,9.42,21,21s-9.42,21-21,21S3,35.58,3,24,12.42,3,24,3m0-1C11.85,2,2,11.85,2,24s9.85,22,22,22,22-9.85,22-22S36.15,2,24,2h0Z\" \/>\n                        <g>\n                            <rect class=\"thumb-down-cls-3 daexthefu-icon-secondary-color\" x=\"10\" y=\"13\" width=\"6\" height=\"15\" rx=\"1.5\" ry=\"1.5\" \/>\n                            <path class=\"thumb-down-cls-1 daexthefu-icon-primary-color\" d=\"m30.57,38.94l-.49.1c-.81.17-1.61-.35-1.78-1.16l-5.3-11.74c-.17-.81,3.16-1.61,3.97-1.78l1.96-.41c.81-.17,1.61.35,1.78,1.16l2.18,10.27c.34,1.61-.7,3.21-2.31,3.56Z\" \/>\n                            <path class=\"thumb-down-cls-1 daexthefu-icon-primary-color\" d=\"m38.17,28h-18.67c-.83,0-1.5-.67-1.5-1.5v-12c0-.83.67-1.5,1.5-1.5h16.27c.71,0,1.33.5,1.47,1.21l2.4,12c.19.93-.53,1.8-1.47,1.8Z\" \/>\n                        <\/g>\n                    <\/g>\n                <\/svg>\t\t\t<\/button>\n\n\t\t\t\t\t\t\t\t\t<\/div>\r\n\t\t\t\t\t<\/div>\r\n\t\t\t\t<\/div>\r\n\r\n\t\t\t\t<div class=\"daexthefu-comment\">\r\n\t\t\t\t\t<div class=\"daexthefu-comment-top-container\">\r\n\t\t\t\t\t\t<label id=\"daexthefu-comment-label\" class=\"daexthefu-comment-label\"><\/label>\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t<div class=\"daexthefu-comment-character-counter-container\">\r\n\t\t\t\t\t\t\t\t<div id=\"daexthefu-comment-character-counter-number\"\r\n\t\t\t\t\t\t\t\t\tclass=\"daexthefu-comment-character-counter-number\"><\/div>\r\n\t\t\t\t\t\t\t\t<div class=\"daexthefu-comment-character-counter-text\"><\/div>\r\n\t\t\t\t\t\t\t<\/div>\r\n\t\t\t\t\t\t\t\t\t\t\t<\/div>\r\n\t\t\t\t\t<textarea id=\"daexthefu-comment-textarea\" class=\"daexthefu-comment-textarea\"\r\n\t\t\t\t\t\t\t\tplaceholder=\"\u0412\u0432\u0435\u0434\u0438\u0442\u0435 \u0432\u0430\u0448\u0435 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435\"\r\n\t\t\t\t\t\t\t\tmaxlength=\"\r\n\t\t\t\t\t\t\t\t400\t\t\t\t\t\t\t\t\t\"><\/textarea>\r\n\t\t\t\t\t<div class=\"daexthefu-comment-buttons-container\">\r\n\t\t\t\t\t\t<button class=\"daexthefu-comment-submit daexthefu-button\">\u041e\u0442\u043f\u0440\u0430\u0432\u0438\u0442\u044c<\/button>\r\n\t\t\t\t\t\t<button class=\"daexthefu-comment-cancel daexthefu-button\">\u041e\u0442\u043c\u0435\u043d\u0438\u0442\u044c<\/button>\r\n\t\t\t\t\t<\/div>\r\n\t\t\t\t<\/div>\r\n\r\n\t\t\t\t<div class=\"daexthefu-successful-submission-text\">\u0421\u043f\u0430\u0441\u0438\u0431\u043e \u0437\u0430 \u043e\u0431\u0440\u0430\u0442\u043d\u0443\u044e \u0441\u0432\u044f\u0437\u044c!<\/div>\r\n\r\n\t\t\t<\/div>\r\n\r\n\t\t\t","protected":false},"excerpt":{"rendered":"<p>Date functions: add days and months, calculate differences, convert formats and write dates out in words.<\/p>\n","protected":false},"author":19,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"_helpful_status":1,"footnotes":""},"categories":[49],"tags":[],"class_list":["post-8824","post","type-post","status-publish","format-standard","hentry","category-shagi-v-botah"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.9 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Formula: Dates and Time<\/title>\n<meta name=\"description\" content=\"Date functions: add days and months, calculate differences, convert formats and write dates out in words.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Formula: Dates and Time\" \/>\n<meta property=\"og:description\" content=\"Date functions: add days and months, calculate differences, convert formats and write dates out in words.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/\" \/>\n<meta property=\"og:site_name\" content=\"\u0411\u0430\u0437\u0430 \u0437\u043d\u0430\u043d\u0438\u0439 BotHelp\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/bothelpru\" \/>\n<meta property=\"article:published_time\" content=\"2026-11-20T10:24:14+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-11-20T10:54:14+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/help.bothelp.io\/wp-content\/uploads\/2025\/10\/image-12.png\" \/>\n\t<meta property=\"og:image:width\" content=\"2296\" \/>\n\t<meta property=\"og:image:height\" content=\"636\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"e.bezmaternykh\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"e.bezmaternykh\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/formula-dates-and-time\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/formula-dates-and-time\\\/\"},\"author\":{\"name\":\"e.bezmaternykh\",\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/#\\\/schema\\\/person\\\/3d6703d74bf6281d752af998b5a7a799\"},\"headline\":\"Formula: Dates and Time\",\"datePublished\":\"2026-11-20T10:24:14+00:00\",\"dateModified\":\"2026-11-20T10:54:14+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/formula-dates-and-time\\\/\"},\"wordCount\":243,\"image\":{\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/formula-dates-and-time\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/help.bothelp.io\\\/wp-content\\\/uploads\\\/2025\\\/10\\\/image-12-1024x284.png\",\"articleSection\":[\"Steps in bots\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/formula-dates-and-time\\\/\",\"url\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/formula-dates-and-time\\\/\",\"name\":\"\u0424\u043e\u0440\u043c\u0443\u043b\u0430: \u0434\u0430\u0442\u044b \u0438 \u0432\u0440\u0435\u043c\u044f - \u0411\u0430\u0437\u0430 \u0437\u043d\u0430\u043d\u0438\u0439 BotHelp\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/formula-dates-and-time\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/formula-dates-and-time\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/help.bothelp.io\\\/wp-content\\\/uploads\\\/2025\\\/10\\\/image-12-1024x284.png\",\"datePublished\":\"2026-11-20T10:24:14+00:00\",\"dateModified\":\"2026-11-20T10:54:14+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/#\\\/schema\\\/person\\\/3d6703d74bf6281d752af998b5a7a799\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/formula-dates-and-time\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/help.bothelp.io\\\/en\\\/formula-dates-and-time\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/formula-dates-and-time\\\/#primaryimage\",\"url\":\"https:\\\/\\\/help.bothelp.io\\\/wp-content\\\/uploads\\\/2025\\\/10\\\/image-12-1024x284.png\",\"contentUrl\":\"https:\\\/\\\/help.bothelp.io\\\/wp-content\\\/uploads\\\/2025\\\/10\\\/image-12-1024x284.png\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/formula-dates-and-time\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"How to Work with BotHelp Service: Setting Up Your Account for Your Business Goals\",\"item\":\"https:\\\/\\\/help.bothelp.io\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Formula: Dates and Time\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/#website\",\"url\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/\",\"name\":\"\u0411\u0430\u0437\u0430 \u0437\u043d\u0430\u043d\u0438\u0439 BotHelp\",\"description\":\"\u0417\u0434\u0435\u0441\u044c \u0432\u044b \u043d\u0430\u0439\u0434\u0435\u0442\u0435 \u043e\u0442\u0432\u0435\u0442\u044b \u043d\u0430 \u0432\u0441\u0435 \u0432\u043e\u043f\u0440\u043e\u0441\u044b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/help.bothelp.io\\\/#\\\/schema\\\/person\\\/3d6703d74bf6281d752af998b5a7a799\",\"name\":\"e.bezmaternykh\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/5cb3cb3e24dd71cdab99be19c756f97e910900e6371c5573a7604f4cb2a523a9?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/5cb3cb3e24dd71cdab99be19c756f97e910900e6371c5573a7604f4cb2a523a9?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/5cb3cb3e24dd71cdab99be19c756f97e910900e6371c5573a7604f4cb2a523a9?s=96&d=mm&r=g\",\"caption\":\"e.bezmaternykh\"},\"url\":\"https:\\\/\\\/help.bothelp.io\\\/en\\\/author\\\/e-bezmaternykh\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Formula: Dates and Time","description":"Date functions: add days and months, calculate differences, convert formats and write dates out in words.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"Date functions: add days and months, calculate differences, convert formats and write dates out in words.","og_locale":"en_US","og_type":"article","og_title":"Formula: Dates and Time","og_description":"Date functions: add days and months, calculate differences, convert formats and write dates out in words.","og_url":"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/","og_site_name":"\u0411\u0430\u0437\u0430 \u0437\u043d\u0430\u043d\u0438\u0439 BotHelp","article_publisher":"https:\/\/www.facebook.com\/bothelpru","article_published_time":"2026-11-20T10:24:14+00:00","article_modified_time":"2026-11-20T10:54:14+00:00","og_image":[{"width":2296,"height":636,"url":"https:\/\/help.bothelp.io\/wp-content\/uploads\/2025\/10\/image-12.png","type":"image\/png"}],"author":"e.bezmaternykh","twitter_card":"summary_large_image","twitter_misc":{"Written by":"e.bezmaternykh"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/#article","isPartOf":{"@id":"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/"},"author":{"name":"e.bezmaternykh","@id":"https:\/\/help.bothelp.io\/#\/schema\/person\/3d6703d74bf6281d752af998b5a7a799"},"headline":"Formula: Dates and Time","datePublished":"2026-11-20T10:24:14+00:00","dateModified":"2026-11-20T10:54:14+00:00","mainEntityOfPage":{"@id":"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/"},"wordCount":243,"image":{"@id":"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/#primaryimage"},"thumbnailUrl":"https:\/\/help.bothelp.io\/wp-content\/uploads\/2025\/10\/image-12-1024x284.png","articleSection":["Steps in bots"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/","url":"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/","name":"\u0424\u043e\u0440\u043c\u0443\u043b\u0430: \u0434\u0430\u0442\u044b \u0438 \u0432\u0440\u0435\u043c\u044f - \u0411\u0430\u0437\u0430 \u0437\u043d\u0430\u043d\u0438\u0439 BotHelp","isPartOf":{"@id":"https:\/\/help.bothelp.io\/#website"},"primaryImageOfPage":{"@id":"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/#primaryimage"},"image":{"@id":"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/#primaryimage"},"thumbnailUrl":"https:\/\/help.bothelp.io\/wp-content\/uploads\/2025\/10\/image-12-1024x284.png","datePublished":"2026-11-20T10:24:14+00:00","dateModified":"2026-11-20T10:54:14+00:00","author":{"@id":"https:\/\/help.bothelp.io\/#\/schema\/person\/3d6703d74bf6281d752af998b5a7a799"},"breadcrumb":{"@id":"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/#primaryimage","url":"https:\/\/help.bothelp.io\/wp-content\/uploads\/2025\/10\/image-12-1024x284.png","contentUrl":"https:\/\/help.bothelp.io\/wp-content\/uploads\/2025\/10\/image-12-1024x284.png"},{"@type":"BreadcrumbList","@id":"https:\/\/help.bothelp.io\/en\/formula-dates-and-time\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"How to Work with BotHelp Service: Setting Up Your Account for Your Business Goals","item":"https:\/\/help.bothelp.io\/"},{"@type":"ListItem","position":2,"name":"Formula: Dates and Time"}]},{"@type":"WebSite","@id":"https:\/\/help.bothelp.io\/en\/#website","url":"https:\/\/help.bothelp.io\/en\/","name":"\u0411\u0430\u0437\u0430 \u0437\u043d\u0430\u043d\u0438\u0439 BotHelp","description":"\u0417\u0434\u0435\u0441\u044c \u0432\u044b \u043d\u0430\u0439\u0434\u0435\u0442\u0435 \u043e\u0442\u0432\u0435\u0442\u044b \u043d\u0430 \u0432\u0441\u0435 \u0432\u043e\u043f\u0440\u043e\u0441\u044b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/help.bothelp.io\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/help.bothelp.io\/#\/schema\/person\/3d6703d74bf6281d752af998b5a7a799","name":"e.bezmaternykh","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/5cb3cb3e24dd71cdab99be19c756f97e910900e6371c5573a7604f4cb2a523a9?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/5cb3cb3e24dd71cdab99be19c756f97e910900e6371c5573a7604f4cb2a523a9?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/5cb3cb3e24dd71cdab99be19c756f97e910900e6371c5573a7604f4cb2a523a9?s=96&d=mm&r=g","caption":"e.bezmaternykh"},"url":"https:\/\/help.bothelp.io\/en\/author\/e-bezmaternykh\/"}]}},"_links":{"self":[{"href":"https:\/\/help.bothelp.io\/en\/wp-json\/wp\/v2\/posts\/8824","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/help.bothelp.io\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/help.bothelp.io\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/help.bothelp.io\/en\/wp-json\/wp\/v2\/users\/19"}],"replies":[{"embeddable":true,"href":"https:\/\/help.bothelp.io\/en\/wp-json\/wp\/v2\/comments?post=8824"}],"version-history":[{"count":4,"href":"https:\/\/help.bothelp.io\/en\/wp-json\/wp\/v2\/posts\/8824\/revisions"}],"predecessor-version":[{"id":9171,"href":"https:\/\/help.bothelp.io\/en\/wp-json\/wp\/v2\/posts\/8824\/revisions\/9171"}],"wp:attachment":[{"href":"https:\/\/help.bothelp.io\/en\/wp-json\/wp\/v2\/media?parent=8824"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/help.bothelp.io\/en\/wp-json\/wp\/v2\/categories?post=8824"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/help.bothelp.io\/en\/wp-json\/wp\/v2\/tags?post=8824"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}